smbd: Fix a memleak in async search ask sharemode
authorVolker Lendecke <vl@samba.org>
Mon, 3 Sep 2018 13:54:48 +0000 (15:54 +0200)
committerRalph Boehme <slow@samba.org>
Mon, 3 Sep 2018 16:44:23 +0000 (18:44 +0200)
commit0bd109b733fbce774feae2142d25f7e828b56bcb
tree9d54b8ea01711948d7311c00c60afb80f77669c8
parent30eb28818d5fbbb35d0965a92f721243aca6ab54
smbd: Fix a memleak in async search ask sharemode

fetch_share_mode_unlocked_parser() takes a "struct
fetch_share_mode_unlocked_state *" as
"private_data". fetch_share_mode_send() used a talloc_zero'ed "struct
share_mode_lock". This lead to the parser putting a "struct
share_mode_lock on the NULL talloc_context where nobody really picked it
up.

Bug: https://bugzilla.samba.org/show_bug.cgi?id=13602
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
source3/locking/share_mode_lock.c