s3/smbd: fix schedule_async_open() timer
commitad8c36125f72e0d5f9ebfc94037a4ae9e7608aad
authorRalph Boehme <slow@samba.org>
Tue, 7 Mar 2017 14:33:55 +0000 (7 15:33 +0100)
committerJeremy Allison <jra@samba.org>
Fri, 10 Mar 2017 02:28:25 +0000 (10 03:28 +0100)
tree119958142eef3a68215322f7ee5aab07e5988927
parentbeaba6222848fb4ff4392b2247c5be1094b1d65b
s3/smbd: fix schedule_async_open() timer

schedule_async_open() was calling defer_open with sharemode lock = NULL,
as a result there was never an active 20 s timeout.

This has been broken since the commits in

$ git log --reverse -p -10 8283fd0e0090ed12b0b12d5acb550642d621b026

Just roll our own deferred record instead of calling defer_open() and
also set up timer that, as a last resort, catches stuck opens and just
exits for now.

Bug: https://bugzilla.samba.org/show_bug.cgi?id=7537

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
source3/smbd/open.c