diff options
author | Volker Lendecke <vl@samba.org> | 2012-05-14 14:57:34 +0200 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2012-05-17 13:17:22 -0700 |
commit | 43296090f93c48aab061c0fd4ed295a0eb64756b (patch) | |
tree | 22e6a65d9dd418e95ddd7287e4d48ad4116b5479 /source3/locking | |
parent | 49237b0cef181f51dc584c8f2b0a718c5a6a97e5 (diff) | |
download | samba-43296090f93c48aab061c0fd4ed295a0eb64756b.tar.gz |
s3: Be less picky on stale share mode entries
If a process died, the share mode entry might be bogus. Ignore those entries.
Signed-off-by: Jeremy Allison <jra@samba.org>
Diffstat (limited to 'source3/locking')
-rw-r--r-- | source3/locking/locking.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/source3/locking/locking.c b/source3/locking/locking.c index 69a6f26cc11..b9fba17a87b 100644 --- a/source3/locking/locking.c +++ b/source3/locking/locking.c @@ -620,7 +620,9 @@ bool is_valid_share_mode_entry(const struct share_mode_entry *e) num_props += (EXCLUSIVE_OPLOCK_TYPE(e->op_type) ? 1 : 0); num_props += (LEVEL_II_OPLOCK_TYPE(e->op_type) ? 1 : 0); - SMB_ASSERT(num_props <= 1); + if (serverid_exists(&e->pid) && (num_props > 1)) { + smb_panic("Invalid share mode entry"); + } return (num_props != 0); } |