Author: jra
Date: 2007-07-18 18:57:23 +0000 (Wed, 18 Jul 2007)
New Revision: 23958

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

Log:
Merge from 3_2-ctdb-tridge as requested by Metze.

/* cope with dead entries from the process not
existing. These should not be considered valid,
otherwise we end up doing zero timeout sharing
violation */

Jeremy.


Modified:
   branches/SAMBA_3_0_25/source/locking/locking.c
   branches/SAMBA_3_2_0/source/locking/locking.c


Changeset:
Modified: branches/SAMBA_3_0_25/source/locking/locking.c
===================================================================
--- branches/SAMBA_3_0_25/source/locking/locking.c      2007-07-18 14:38:18 UTC 
(rev 23957)
+++ branches/SAMBA_3_0_25/source/locking/locking.c      2007-07-18 18:57:23 UTC 
(rev 23958)
@@ -929,6 +929,14 @@
 {
        int num_props = 0;
 
+       if (e->op_type == UNUSED_SHARE_MODE_ENTRY) {
+               /* cope with dead entries from the process not
+                  existing. These should not be considered valid,
+                  otherwise we end up doing zero timeout sharing
+                  violation */
+               return False;
+       }
+
        num_props += ((e->op_type == NO_OPLOCK) ? 1 : 0);
        num_props += (EXCLUSIVE_OPLOCK_TYPE(e->op_type) ? 1 : 0);
        num_props += (LEVEL_II_OPLOCK_TYPE(e->op_type) ? 1 : 0);

Modified: branches/SAMBA_3_2_0/source/locking/locking.c
===================================================================
--- branches/SAMBA_3_2_0/source/locking/locking.c       2007-07-18 14:38:18 UTC 
(rev 23957)
+++ branches/SAMBA_3_2_0/source/locking/locking.c       2007-07-18 18:57:23 UTC 
(rev 23958)
@@ -937,6 +937,14 @@
 {
        int num_props = 0;
 
+       if (e->op_type == UNUSED_SHARE_MODE_ENTRY) {
+               /* cope with dead entries from the process not
+                  existing. These should not be considered valid,
+                  otherwise we end up doing zero timeout sharing
+                  violation */
+               return False;
+       }
+
        num_props += ((e->op_type == NO_OPLOCK) ? 1 : 0);
        num_props += (EXCLUSIVE_OPLOCK_TYPE(e->op_type) ? 1 : 0);
        num_props += (LEVEL_II_OPLOCK_TYPE(e->op_type) ? 1 : 0);

Reply via email to