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

tridge at samba.org tridge at samba.org
Sun Nov 7 10:20:50 GMT 2004


Author: tridge
Date: 2004-11-07 10:20:50 +0000 (Sun, 07 Nov 2004)
New Revision: 3597

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

Log:
implement a suggestion from abartlet. By taking a refernce to the
database in the opendb lck, we ensure that the database is not closed
before the lock is gone. That ensures the lock destructor doesn't work
on a closed database.


Modified:
   branches/SAMBA_4_0/source/ntvfs/common/opendb.c


Changeset:
Modified: branches/SAMBA_4_0/source/ntvfs/common/opendb.c
===================================================================
--- branches/SAMBA_4_0/source/ntvfs/common/opendb.c	2004-11-07 10:09:50 UTC (rev 3596)
+++ branches/SAMBA_4_0/source/ntvfs/common/opendb.c	2004-11-07 10:20:50 UTC (rev 3597)
@@ -130,7 +130,7 @@
 		return NULL;
 	}
 
-	lck->odb = odb;
+	lck->odb = talloc_reference(lck, odb);
 	lck->key.dptr = talloc_memdup(lck, file_key->data, file_key->length);
 	lck->key.dsize = file_key->length;
 	if (lck->key.dptr == NULL) {



More information about the samba-cvs mailing list