summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
Diffstat (limited to 'source3')
-rw-r--r--source3/smbd/close.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/source3/smbd/close.c b/source3/smbd/close.c
index c87b1a000b..1bac2a1cdf 100644
--- a/source3/smbd/close.c
+++ b/source3/smbd/close.c
@@ -179,9 +179,15 @@ static void notify_deferred_opens(struct smbd_server_connection *sconn,
num_deferred = 0;
for (i=0; i<lck->data->num_share_modes; i++) {
- if (is_deferred_open_entry(&lck->data->share_modes[i])) {
- num_deferred += 1;
+ struct share_mode_entry *e = &lck->data->share_modes[i];
+
+ if (!is_deferred_open_entry(e)) {
+ continue;
+ }
+ if (share_mode_stale_pid(lck->data, i)) {
+ continue;
}
+ num_deferred += 1;
}
if (num_deferred == 0) {
return;