svn commit: samba r15612 - in branches/SAMBA_4_0/source/ntvfs/common: .

metze at samba.org metze at samba.org
Mon May 15 10:45:39 GMT 2006


Author: metze
Date: 2006-05-15 10:45:38 +0000 (Mon, 15 May 2006)
New Revision: 15612

WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=15612

Log:
look at the lock_type and not at the notify_ptr being NULL or not

metze
Modified:
   branches/SAMBA_4_0/source/ntvfs/common/brlock.c


Changeset:
Modified: branches/SAMBA_4_0/source/ntvfs/common/brlock.c
===================================================================
--- branches/SAMBA_4_0/source/ntvfs/common/brlock.c	2006-05-15 06:54:13 UTC (rev 15611)
+++ branches/SAMBA_4_0/source/ntvfs/common/brlock.c	2006-05-15 10:45:38 UTC (rev 15612)
@@ -411,7 +411,7 @@
 		    lock->fnum == fnum &&
 		    lock->start == start &&
 		    lock->size == size &&
-		    lock->notify_ptr == NULL) {
+		    lock->lock_type < PENDING_READ_LOCK) {
 			/* found it - delete it */
 			if (count == 1) {
 				if (tdb_delete(brl->w->tdb, kbuf) != 0) {
@@ -487,7 +487,8 @@
 	for (i=0; i<count; i++) {
 		struct lock_struct *lock = &locks[i];
 		
-		if (lock->notify_ptr == notify_ptr &&
+		if (lock->lock_type >= PENDING_READ_LOCK &&
+		    lock->notify_ptr == notify_ptr &&
 		    lock->context.server == brl->server) {
 			/* found it - delete it */
 			if (count == 1) {



More information about the samba-cvs mailing list