svn commit: samba r6162 - in trunk/source/smbd: .

jra at samba.org jra at samba.org
Fri Apr 1 00:54:55 GMT 2005


Author: jra
Date: 2005-04-01 00:54:54 +0000 (Fri, 01 Apr 2005)
New Revision: 6162

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

Log:
Well I never, all this time the t2open code was incorrectly decting
oplock requests and no one noticed. Hmmm. Don't think this is a commonly
used codepath :-).
Jeremy.

Modified:
   trunk/source/smbd/trans2.c


Changeset:
Modified: trunk/source/smbd/trans2.c
===================================================================
--- trunk/source/smbd/trans2.c	2005-04-01 00:21:56 UTC (rev 6161)
+++ trunk/source/smbd/trans2.c	2005-04-01 00:54:54 UTC (rev 6162)
@@ -744,7 +744,11 @@
 
 	open_mode = SVAL(params, 2);
 	open_attr = SVAL(params,6);
-	oplock_request = (((SVAL(params,0)|(1<<1))>>1) | ((SVAL(params,0)|(1<<2))>>1));
+        oplock_request = (SVAL(params,0) & REQUEST_OPLOCK) ? EXCLUSIVE_OPLOCK : 0;
+        if (oplock_request) {
+                oplock_request |= (SVAL(params,0) & REQUEST_BATCH_OPLOCK) ? BATCH_OPLOCK : 0;
+        }
+
 #if 0
 	return_additional_info = BITSETW(params,0);
 	open_sattr = SVAL(params, 4);



More information about the samba-cvs mailing list