dm_handle_to_snap
Extracts a snapshot ID from a handle.
Synopsis
int dm_handle_to_snap(
void *hanp, /* IN */
size_t hlen, /* IN */
dm_snap_t *isnapp /* OUT */
);
Description
Use the dm_handle_to_snap function to extract a snapshot ID from a handle. dm_handle_to_snap() is a GPFS-specific DMAPI function. It is not part of the open standard.
Parameters
- void *hanp (IN)
- A pointer to an opaque DM handle previously returned by DMAPI.
- size_t hlen (IN)
- The length of the handle in bytes.
- dm_snap_t *isnapp (OUT)
- A pointer to the snapshot ID.
Return values
Zero is returned on success.
On error, -1 is returned, and the global errno is set to one
of the following values:
- [EBADF]
- The file handle does not refer to an existing or accessible object.
- [EFAULT]
- The system detected an invalid address in attempting to use an argument.
- [EINVAL]
- The argument token is not a valid token.
- [ENOMEM]
- DMAPI could not obtain the required resources to complete the call.
- [ENOSYS]
- Function is not supported by the DM implementation.
- [EPERM]
- The caller does not hold the appropriate privilege.