---
name: "ixp_pread"
section: "3"
platform: "linux"
package: "libixp-dev"
version: "0.6~20121202+hg148-5"
release: "Debian 11 (Bullseye)"
platforms: ["linux"]
url: "https://new.carta.tech/ixp_pread"
---

# ixp\_pread(3)

## NAME

ixp\_read, ixp\_pread

## SYNOPSIS

```
#include <ixp.h>
long ixp_read(IxpCFid *fid, void *buf, long count);
long ixp_pread(IxpCFid *fid, void *buf, long count, int64_t offset);
```

## PARAMETERS

- buf

  A buffer in which to store the read data.

- count

  The number of bytes to read.

- offset

  The offset at which to begin reading.

## DESCRIPTION

ixp\_read and ixp\_pread each read *count* bytes of data from the file pointed to by *fid*, into *buf*. ixp\_read begins reading at its stored offset, and increments it by the number of bytes read. ixp\_pread reads beginning at *offset* and does not alter *fid*'s stored offset.

## RETURN VALUE

These functions return the number of bytes read on success and -1 on failure.

## SEE ALSO

[ixp\_mount(3)](/ixp_mount/3.md), [ixp\_open(3)](/ixp_open/3.md), [ixp\_write(3)](/ixp_write/3.md)
