]> git.sur5r.net Git - openldap/commitdiff
Fix darwin sem_open() names
authorHoward Chu <hyc@symas.com>
Fri, 13 Jul 2012 18:57:11 +0000 (11:57 -0700)
committerHoward Chu <hyc@symas.com>
Fri, 13 Jul 2012 21:14:36 +0000 (14:14 -0700)
Must begin with '/'

libraries/libmdb/mdb.c

index fc889ce7ade76807eb8302a0e5d7108a73639659..44365337c7afb9e1a7daa16c2a281fa1ac783c6e 100644 (file)
@@ -2922,7 +2922,7 @@ mdb_env_setup_locks(MDB_env *env, char *lpath, int mode, int *excl)
                val.mv_data = &idbuf;
                val.mv_size = sizeof(idbuf);
                mdb_hash_hex(&val, hexbuf);
-               sprintf(env->me_txns->mti_rmname, "MDBr%s", hexbuf);
+               sprintf(env->me_txns->mti_rmname, "/MDBr%s", hexbuf);
                if (sem_unlink(env->me_txns->mti_rmname)) {
                        rc = ErrCode();
                        if (rc != ENOENT && rc != EINVAL)
@@ -2933,7 +2933,7 @@ mdb_env_setup_locks(MDB_env *env, char *lpath, int mode, int *excl)
                        rc = ErrCode();
                        goto fail;
                }
-               sprintf(env->me_txns->mti_wmname, "MDBw%s", hexbuf);
+               sprintf(env->me_txns->mti_wmname, "/MDBw%s", hexbuf);
                if (sem_unlink(env->me_txns->mti_wmname)) {
                        rc = ErrCode();
                        if (rc != ENOENT && rc != EINVAL)