Changeset 862 for trunk/server/lib/tdb/common
- Timestamp:
- May 13, 2014, 11:39:04 AM (11 years ago)
- Location:
- trunk/server
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/server
- Property svn:mergeinfo changed
/vendor/current merged: 860
- Property svn:mergeinfo changed
-
trunk/server/lib/tdb/common/lock.c
r857 r862 52 52 int lockFile = 0; 53 53 54 if (off == ACTIVE_LOCK )54 if (off == ACTIVE_LOCK || off == OPEN_LOCK || off == TRANSACTION_LOCK) 55 55 lockFile = tdb->hActiveLock; 56 56 else … … 77 77 78 78 TDB_LOG((tdb, TDB_DEBUG_TRACE,"fcntl_lock: (fd=%d) offset=%lld rw_type=%d len=%lld waitflag=%d (rc=%d)\n", 79 tdb->fd, off, rw, len, waitflag, rc));79 lockFile, off, rw, len, waitflag, rc)); 80 80 81 81 return rc; … … 162 162 int rc = 0; 163 163 int lockFile = 0; 164 if (off == ACTIVE_LOCK )164 if (off == ACTIVE_LOCK || off == OPEN_LOCK || off == TRANSACTION_LOCK) 165 165 lockFile = tdb->hActiveLock; 166 166 else … … 182 182 183 183 TDB_LOG((tdb, TDB_DEBUG_TRACE,"fcntl_unlock: (fd=%d) offset=%lld rw_type=%d len=%lld (rc=%d)\n", 184 tdb->fd, off, rw, len, rc));184 lockFile, off, rw, len, rc)); 185 185 186 186 return rc; -
trunk/server/lib/tdb/common/open.c
r857 r862 303 303 fcntl(tdb->fd, F_SETFD, v | FD_CLOEXEC); 304 304 305 #ifdef __OS2__ 306 if (os2_crtActiveLock(tdb, name, 1, mode) != 0) 307 goto fail; 308 #endif 309 305 310 /* ensure there is only one process initialising at once */ 306 311 if (tdb_nest_lock(tdb, OPEN_LOCK, F_WRLCK, TDB_LOCK_WAIT) == -1) { … … 309 314 goto fail; /* errno set by tdb_brlock */ 310 315 } 311 312 #ifdef __OS2__313 if (os2_crtActiveLock(tdb, name, 1, mode) != 0)314 goto fail;315 #endif316 316 317 317 /* we need to zero database if we are the only one with it open */
Note:
See TracChangeset
for help on using the changeset viewer.