You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by jo...@apache.org on 2024/01/05 14:44:33 UTC

svn commit: r1915093 - /apr/apr/trunk/include/apr_dbm.h

Author: jorton
Date: Fri Jan  5 14:44:33 2024
New Revision: 1915093

URL: http://svn.apache.org/viewvc?rev=1915093&view=rev
Log:
* include/apr_dbm.h: Document that drivers don't guarantee
  cross-process/thread-safe locking for concurrent r/w use.

Modified:
    apr/apr/trunk/include/apr_dbm.h

Modified: apr/apr/trunk/include/apr_dbm.h
URL: http://svn.apache.org/viewvc/apr/apr/trunk/include/apr_dbm.h?rev=1915093&r1=1915092&r2=1915093&view=diff
==============================================================================
--- apr/apr/trunk/include/apr_dbm.h (original)
+++ apr/apr/trunk/include/apr_dbm.h Fri Jan  5 14:44:33 2024
@@ -154,6 +154,11 @@ APR_DECLARE(apr_status_t) apr_dbm_open2(
  * @param cntxt The pool to use when creating the dbm
  * @remark The dbm name may not be a true file name, as many dbm packages
  * append suffixes for separate data and index files.
+ * @warning DBM drivers do not guarantee thread-safe or cross-process
+ * locking; multiple threads or processes reading and writing
+ * concurrently to the database is not safe and results in
+ * undefined behaviour (likely database corruption and possible
+ * crashes).
  */
 APR_DECLARE(apr_status_t) apr_dbm_open(apr_dbm_t **dbm, const char *name,
                                        apr_int32_t mode, apr_fileperms_t perm,