ipsec_get_policylen()
Get the length of the IPsec policy
Synopsis:
#include <netinet6/ipsec.h>
int ipsec_get_policylen(char *buf);
Arguments:
- buf
- A pointer to an IPsec policy structure
struct sadb_x_policy.
Library:
libipsec
Use the -l ipsec option to qcc to link against this library.
Description:
The ipsec_get_policylen() function gets the length of the IPsec policy. See ipsec_set_policy() for details about the policies.
You may want the length of the generated buffer when calling setsockopt(). The ipsec_get_policylen() function returns the length.
Returns:
The size of the buffer, or a negative value if an error occurs.
Examples:
See ipsec_set_policy().
Classification:
| Safety: | |
|---|---|
| Cancellation point | No |
| Interrupt handler | Yes |
| Signal handler | Yes |
| Thread | Yes |
Page updated:
