Changeset 834 for trunk/server/lib/tdb/common/transaction.c
- Timestamp:
- Nov 25, 2013, 4:35:16 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/server/lib/tdb/common/transaction.c
r745 r834 486 486 /* get a read lock from the freelist to the end of file. This 487 487 is upgraded to a write lock during the commit */ 488 #ifndef __OS2__ // YD the transation lock is an exclusive lock for us, it is enough.489 488 if (tdb_allrecord_lock(tdb, F_RDLCK, TDB_LOCK_WAIT, true) == -1) { 490 489 TDB_LOG((tdb, TDB_DEBUG_ERROR, "tdb_transaction_start: failed to get hash locks\n")); 491 490 goto fail_allrecord_lock; 492 491 } 493 #endif494 492 495 493 /* setup a copy of the hash table heads so the hash scan in … … 523 521 524 522 fail: 525 #ifndef __OS2__ // YD the transation lock is an exclusive lock for us, it is enough.526 523 tdb_allrecord_unlock(tdb, F_RDLCK, false); 527 #endif528 524 fail_allrecord_lock: 529 525 tdb_transaction_unlock(tdb, F_WRLCK); … … 949 945 950 946 /* upgrade the main transaction lock region to a write lock */ 951 #ifndef __OS2__ // YD the global lock is an exclusive lock for us, it is enough952 947 if (tdb_allrecord_upgrade(tdb) == -1) { 953 948 TDB_LOG((tdb, TDB_DEBUG_ERROR, "tdb_transaction_prepare_commit: failed to upgrade hash locks\n")); … … 955 950 return -1; 956 951 } 957 #endif958 952 959 953 /* get the open lock - this prevents new users attaching to the database
Note:
See TracChangeset
for help on using the changeset viewer.