summaryrefslogtreecommitdiffstats
path: root/source3/locking/share_mode_lock.c
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2014-06-29 08:56:03 +0000
committerJeremy Allison <jra@samba.org>2014-06-30 22:28:15 +0200
commit9f2e90754bcb7bf5f7159d07f0bc5fe754e71bf5 (patch)
tree10a027bf8936e951044b2ed99cef8f30269c329a /source3/locking/share_mode_lock.c
parent4964b0606652169cc8dc59ee45bceae80ac4c46a (diff)
downloadsamba-9f2e90754bcb7bf5f7159d07f0bc5fe754e71bf5.tar.gz
samba-9f2e90754bcb7bf5f7159d07f0bc5fe754e71bf5.tar.xz
samba-9f2e90754bcb7bf5f7159d07f0bc5fe754e71bf5.zip
smbstatus: Fix an uninitialized variable
We only print valid share mode entries, stale ones don't count. In traverse, let the callback decide about staleness. https://bugzilla.samba.org/show_bug.cgi?id=10680 Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
Diffstat (limited to 'source3/locking/share_mode_lock.c')
-rw-r--r--source3/locking/share_mode_lock.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/source3/locking/share_mode_lock.c b/source3/locking/share_mode_lock.c
index 5e25404426..12f499b1b9 100644
--- a/source3/locking/share_mode_lock.c
+++ b/source3/locking/share_mode_lock.c
@@ -484,6 +484,7 @@ static int traverse_fn(struct db_record *rec, void *_state)
NDR_PRINT_DEBUG(share_mode_data, d);
}
for (i=0; i<d->num_share_modes; i++) {
+ d->share_modes[i].stale = false; /* [skip] in idl */
state->fn(&d->share_modes[i],
d->servicepath, d->base_name,
state->private_data);