summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2012-06-01 15:15:07 +0200
committerStefan Metzmacher <metze@samba.org>2012-06-01 18:58:30 +0200
commit29a51a22df68ae8929bd8312df03c72bbfa26f81 (patch)
treec1456f12f4062de6249996c4e2b258b5bd650a42 /source3
parenteaf9b86d601d7564199bdc037dc5024e6a4e5908 (diff)
downloadsamba-29a51a22df68ae8929bd8312df03c72bbfa26f81.tar.gz
samba-29a51a22df68ae8929bd8312df03c72bbfa26f81.tar.bz2
samba-29a51a22df68ae8929bd8312df03c72bbfa26f81.zip
s3: Avoid a lot of calls to serverid_exists()
Signed-off-by: Stefan Metzmacher <metze@samba.org> Autobuild-User: Stefan Metzmacher <metze@samba.org> Autobuild-Date: Fri Jun 1 18:58:30 CEST 2012 on sn-devel-104
Diffstat (limited to 'source3')
-rw-r--r--source3/locking/locking.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source3/locking/locking.c b/source3/locking/locking.c
index 00a46fa619..76c2bc7a48 100644
--- a/source3/locking/locking.c
+++ b/source3/locking/locking.c
@@ -620,7 +620,7 @@ 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);
- if (serverid_exists(&e->pid) && (num_props > 1)) {
+ if ((num_props > 1) && serverid_exists(&e->pid)) {
smb_panic("Invalid share mode entry");
}
return (num_props != 0);