Warning: main(/www/www/htdocs/style/globals.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/lib_ref/i/inet6_option_next.html on line 1

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/globals.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/lib_ref/i/inet6_option_next.html on line 1

Warning: main(/www/www/htdocs/style/header.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/lib_ref/i/inet6_option_next.html on line 8

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/header.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/lib_ref/i/inet6_option_next.html on line 8

inet6_option_next()

Find the next IPv6 hop-by-hop or destination option

Synopsis:

#include <netinet/in.h>

int inet6_option_next(const struct cmsghdr *cmsg, 
                      u_int8_t **tptrp);

Arguments:

cmsg
A pointer to the cmsghdr structure that must have been initialized by inet6_option_init().
tptrp
A pointer to a pointer to an 8-bit byte.

Library:

libsocket

Use the -l socket option to qcc to link against this library.

Description:

This inet6_option_next() function finds the next hop-by-hop option or destination option in an ancillary data object. If another option remains to be processed, the return value of the function is 0 and *tptrp points to the 8-bit option type field the option data.

The cmsg variable is a pointer to cmsghdr structure for which cmsg_level equals IPPROTO_IPV6 and cmsg_type equals either IPV6_HOPOPTS or IPV6_DSTOPTS.

The tptrp is a pointer to a pointer to an 8-bit byte and *tptrp is used by the function to remember its place in the ancillary data object each time the function is called. The first time you call this function for a given ancillary data object, you must set *tptrp to NULL.

Each time this function returns success, *tptrp points to the 8-bit option type field for the next option to be processed.

Returns:

0
The option is located and the *tptrp points to the 8-bit option type field.
-1 with *tptrp pointing to NULL
No more options to process.
-1 with *tptrp pointing to non-NULL
An error has occurred.

Classification:

RFC 2292

Safety:
Cancellation point No
Interrupt handler No
Signal handler Yes
Thread Yes

See also:

inet6_option_alloc(), inet6_option_append(), inet6_option_find(), inet6_option_init(), inet6_option_space()

Based on:


Warning: main(/www/www/htdocs/style/footer.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/lib_ref/i/inet6_option_next.html on line 176

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/footer.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/lib_ref/i/inet6_option_next.html on line 176