Standards / Extensions | C or C++ | Dependencies |
---|---|---|
RFC3542 |
both | z/OS® V1R7 |
#define _OPEN_SYS_SOCK_IPV6
#include <netinet/in.h>
int inet6_opt_find(void *extbuf, socklen_t extlen, int offset,
uint8_t type, socklen_t *lenp, void **databufp);
inet6_opt_find() is similar to inet6_opt_next(), except it lets the caller specify the option type to be searched for.
If successful, inet6_opt_find() returns the updated "previous" total length computed by advancing past the option that was returned and past any options that did not match the type.
Upon failure, returns -1 and errno is set to one of the following:
EINVAL If one of the following is true:
The returned "previous" length can be passed to subsequent calls of inet6_opt_find() for finding the next occurrence of the same option type.