Writes a new Routing header that sends datagrams along the reverse route of a Routing header extension header.
The inet6_rth_reverse subroutine takes a Routing header extension header (pointed to by the first argument) and writes a new Routing header that sends datagrams along the reverse of that route. The function reverses the order of the addresses and sets the segleft member in the new Routing header to the number of segments. Both arguments are allowed to point to the same buffer (that is, the reversal can occur in place).
Item | Description |
---|---|
in | Points to the original Routing header extension header. |
out | Points to the new Routing header route that reverses the route of in. |
Item | Description |
---|---|
0 | The reverse Routing header was successfully created. |
–1 | The reverse Routing header could not be created. |