diff options
author | Jim Jagielski <jim@apache.org> | 2014-04-28 13:14:45 +0000 |
---|---|---|
committer | Jim Jagielski <jim@apache.org> | 2014-04-28 13:14:45 +0000 |
commit | d80c76dc4b5a2e2ff52d3b3fef39d09c85b989d3 (patch) | |
tree | dfd16e36a3c2f48f5f1f2d0be1a8dd6c21b1716d /include/apr_shm.h | |
parent | de420cf010b9ea111e8119814cc9a7071186139b (diff) | |
download | apr-d80c76dc4b5a2e2ff52d3b3fef39d09c85b989d3.tar.gz |
Add apr_shm_delete()
git-svn-id: https://svn.apache.org/repos/asf/apr/apr/trunk@1590624 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'include/apr_shm.h')
-rw-r--r-- | include/apr_shm.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/include/apr_shm.h b/include/apr_shm.h index 2ed86e219..635c654b1 100644 --- a/include/apr_shm.h +++ b/include/apr_shm.h @@ -137,6 +137,21 @@ APR_DECLARE(apr_status_t) apr_shm_remove(const char *filename, apr_pool_t *pool); /** + * Delete named resource associated with a shared memory segment, + * preventing attachments to the resource. + * @param m The shared memory segment structure to delete. + * @remark This function is only supported on platforms which support + * name-based shared memory segments, and will return APR_ENOTIMPL on + * platforms without such support. Removing the file while the shm + * is in use is not entirely portable, caller may use this to enhance + * obscurity of the resource, but be prepared for the call to fail, + * and for concurrent attempts to create a resource of the same name + * to also fail. The pool cleanup of apr_shm_create (apr_shm_destroy) + * also removes the named resource. + */ +APR_DECLARE(apr_status_t) apr_shm_delete(apr_shm_t *m); + +/** * Destroy a shared memory segment and associated memory. * @param m The shared memory segment structure to destroy. */ |