From bed323cebcfcf3298002ea8bc2eb6787419043b6 Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Thu, 1 May 2014 10:58:51 -0700 Subject: s3 : smbd : Protect all possible code paths from fsp->op == NULL. In changes to come this will be possible for an INTERNAL_OPEN_ONLY. The protection was already in place for some code paths, this makes the coverage compete. Bug 10564 - Lock order violation and file lost https://bugzilla.samba.org/show_bug.cgi?id=10564 Signed-off-by: Jeremy Allison Reviewed-by: Volker Lendecke --- source3/smbd/scavenger.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'source3/smbd/scavenger.c') diff --git a/source3/smbd/scavenger.c b/source3/smbd/scavenger.c index e6e28788065..122305e04bf 100644 --- a/source3/smbd/scavenger.c +++ b/source3/smbd/scavenger.c @@ -418,6 +418,9 @@ void scavenger_schedule_disconnected(struct files_struct *fsp) struct scavenger_message msg; DATA_BLOB msg_blob; + if (fsp->op == NULL) { + return; + } nttime_to_timeval(&disconnect_time, fsp->op->global->disconnect_time); timeout_usec = 1000 * fsp->op->global->durable_timeout_msec; until = timeval_add(&disconnect_time, -- cgit v1.2.1