summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2001-09-18 22:59:12 +0000
committerJeremy Allison <jra@samba.org>2001-09-18 22:59:12 +0000
commita27509937ca8bb57b9d7cc6cd7a3dd06ac4a0455 (patch)
treeca3729d2759f460ba8e9d659fbc097756dc0e79e
parentc64cd552c404f74f4f7e6aa2b4e1a6856c617011 (diff)
downloadsamba-a27509937ca8bb57b9d7cc6cd7a3dd06ac4a0455.tar.gz
samba-a27509937ca8bb57b9d7cc6cd7a3dd06ac4a0455.tar.bz2
samba-a27509937ca8bb57b9d7cc6cd7a3dd06ac4a0455.zip
Roll back earlier fix after talking with Andrew. The write_lock_record and
unlock are explicitly non-blocking. I will add a comment to this effect later. Jeremy. (This used to be commit e4b41a8f31729dfec92c4cb1f8b4759446cac0ff)
-rw-r--r--source3/tdb/tdb.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/source3/tdb/tdb.c b/source3/tdb/tdb.c
index 0207b00222..4eb851a943 100644
--- a/source3/tdb/tdb.c
+++ b/source3/tdb/tdb.c
@@ -996,11 +996,11 @@ static int write_lock_record(TDB_CONTEXT *tdb, tdb_off off)
for (i = &tdb->travlocks; i; i = i->next)
if (i->off == off)
return -1;
- return tdb_brlock(tdb, off, F_WRLCK, F_SETLKW, 1);
+ return tdb_brlock(tdb, off, F_WRLCK, F_SETLK, 1);
}
static int write_unlock_record(TDB_CONTEXT *tdb, tdb_off off)
{
- return tdb_brlock(tdb, off, F_UNLCK, F_SETLKW, 0);
+ return tdb_brlock(tdb, off, F_UNLCK, F_SETLK, 0);
}
/* fcntl locks don't stack: avoid unlocking someone else's */
static int unlock_record(TDB_CONTEXT *tdb, tdb_off off)