---
name: "ne_set_request_body_fd64"
section: "3"
platform: "linux"
package: "libneon27-dev"
version: "0.29.3-3"
release: "Debian 6.0 (Squeeze)"
platforms: ["linux"]
url: "https://new.carta.tech/ne_set_request_body_buffer"
---

# ne\_set\_request\_body\_fd64(3)

include a message body with a request

Part of [ne\_set\_request\_body\_buffer(3)](/ne_set_request_body_buffer/3.md).

## NAME

ne\_set\_request\_body\_buffer, ne\_set\_request\_body\_fd, ne\_set\_request\_body\_fd64 - include a message body with a request

## SYNOPSIS

```
#include <ne_request.h>
```

**void ne\_set\_request\_body\_buffer(ne\_request \****req***, const char \****buf***, size\_t** *count***);**

**int ne\_set\_request\_body\_fd(ne\_request \****req***, int** *fd***, off\_t** *begin***, off\_t** *length***);**

## DESCRIPTION

The **ne\_set\_request\_body\_buffer** function specifies that a message body should be included with the body, which is stored in the *count* bytes buffer *buf*.

The **ne\_set\_request\_body\_fd** function can be used to include a message body with a request which is read from a file descriptor. The body is read from the file descriptor *fd*, which must be a associated with a seekable file (not a pipe, socket, or FIFO). *count* bytes are read, beginning at offset *begin* (hence, passing *begin* as zero means the body is read from the beginning of the file).

For all the above functions, the source of the request body must survive until the request has been dispatched; neither the memory buffer passed to **ne\_set\_request\_body\_buffer** nor the file descriptor passed to **ne\_set\_request\_body\_fd** are copied internally.

## SEE ALSO

ne\_request\_create

## AUTHOR

**Joe Orton** \<neon@lists.manyfish.co.uk\>

Author.

## COPYRIGHT
