Skip to content

Commit 88610ab

Browse files
committed
* include/apr_dbm.h: Document that drivers don't guarantee
cross-process/thread-safe locking for concurrent r/w use. git-svn-id: https://svn.apache.org/repos/asf/apr/apr/trunk@1915093 13f79535-47bb-0310-9956-ffa450edef68
1 parent a5d5016 commit 88610ab

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

include/apr_dbm.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,6 +154,11 @@ APR_DECLARE(apr_status_t) apr_dbm_open2(apr_dbm_t **pdb,
154154
* @param cntxt The pool to use when creating the dbm
155155
* @remark The dbm name may not be a true file name, as many dbm packages
156156
* append suffixes for separate data and index files.
157+
* @warning DBM drivers do not guarantee thread-safe or cross-process
158+
* locking; multiple threads or processes reading and writing
159+
* concurrently to the database is not safe and results in
160+
* undefined behaviour (likely database corruption and possible
161+
* crashes).
157162
*/
158163
APR_DECLARE(apr_status_t) apr_dbm_open(apr_dbm_t **dbm, const char *name,
159164
apr_int32_t mode, apr_fileperms_t perm,

0 commit comments

Comments
 (0)