acl_get_entry()
QNX SDP8.0C Library ReferenceAPIDeveloper
Get an entry in an access control list (ACL)
Synopsis:
#include <sys/acl.h>
int acl_get_entry( acl_t acl,
                   int entry_id,
                   acl_entry_t *entry_p );
Arguments:
- acl
 - A pointer to the access control list that you want to get an entry from.
 - entry_id
 - The ID of the entry you want to get; one of the following:
  
- ACL_FIRST_ENTRY — get the first entry in the ACL.
 - ACL_NEXT_ENTRY — get the next entry in the ACL.
 
 - entry_p
 - A pointer to a location where the function can store a pointer to the entry.
 
Library:
libc
Use the -l c option to qcc to link against this library. This library is usually included automatically.
Description:
The acl_get_entry() function gets an entry from an access control list. Each ACL remembers which entry is the current one.
The ACL entry's pointer returned by acl_get_entry() becomes invalid after calling these functions:
- acl_valid()
 - acl_create_entry()
 - acl_calc_mask()
 - acl_delete_entry()
 - acl_set_file()
 - acl_set_fd()
 
Returns:
- 1
 - An entry was found.
 - 0
 - The ACL has no entries, or the last entry was returned by a previous call to acl_get_entry().
 - -1
 - An error occurred (errno is set).
 
Errors:
- EINVAL
 - The value of entry_id isn't ACL_FIRST_ENTRY or ACL_NEXT_ENTRY.
 
Classification:
This function is based on the withdrawn POSIX draft P1003.1e.
| Safety: | |
|---|---|
| Cancellation point | No | 
| Signal handler | No | 
| Thread | Yes | 
Page updated: 
