---
name: "lc_channel_oti_peek"
section: "3"
platform: "linux"
package: "liblibrecast-dev"
version: "0.9.1-1"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/lc_channel_oti_peek"
---

# lc\_channel\_oti\_peek(3)

peek at OTI header

## NAME

lc\_channel\_oti\_peek - peek at OTI header

## LIBRARY

Librecast library (*liblibrecast*, *-llibrecast*)

## SYNOPSIS

```
#include <librecast/net.h>
```

**int lc\_channel\_oti\_peek(lc\_channel\_t** *\*chan***, rq\_oti\_t** *\*oti***, rq\_scheme\_t** *\*scheme***);**

Compile and link with *-llibrecast*.

## DESCRIPTION

The **lc\_channel\_oti\_peek**() function peeks at the OTI header (RaptorQ FEC Object Transmission Information header - see RFC 6330) in the next packet of the socket bound to channel *chan* and sets *oti* and *scheme* accordingly.

## RETURN VALUE

**lc\_channel\_oti\_peek**() returns zero on success. On error, -1 is returned, and *errno* is set to indicate the error.

## ERRORS

- **EBADMSG**

  The header is malformed, or T does not match the expected value for *chan*.

*errno* can also be set to any of the errors returned by **lc\_socket\_recv**(3)

## SEE ALSO

**lc\_channel\_new**(3), **lc\_channel\_close**(3), **lc\_channel\_recv**(3), [**lc\_channel\_coding\_set**(3)](/lc_channel_coding_set/3.md), **lc\_socket\_recv**(3) [**rq\_pid2sbn**(3)](/rq_pid2sbn/3.md), [**rq\_pid2esi**(3)](/rq_pid2esi/3.md), [**rq\_pidset**(3)](/rq_pidset/3.md), [**rq\_pidsetsbn**(3)](/rq_pidsetsbn/3.md), [**rq\_pidsetesi**(3)](/rq_pidsetesi/3.md), [**lcrq**(7)](/lcrq/7.md)
