summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2013-01-27 11:01:07 +0100
committerStefan Metzmacher <metze@samba.org>2013-01-27 12:23:01 +0100
commit431692df422c3cac71ca12b7e89296172dfcf684 (patch)
treef31f5fb0a85186a9df935c74360f7f8027aeb3d5
parent7e7cd07c405f8b66f5979047cb1a50e1e7a55edd (diff)
downloadsamba-431692df422c3cac71ca12b7e89296172dfcf684.tar.gz
samba-431692df422c3cac71ca12b7e89296172dfcf684.tar.xz
samba-431692df422c3cac71ca12b7e89296172dfcf684.zip
s4:service_task: prevent a segfault if task->msg_ctx is not initialized yet
Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
-rw-r--r--source4/smbd/service_task.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source4/smbd/service_task.c b/source4/smbd/service_task.c
index 4531c3aebc..9a30cd2105 100644
--- a/source4/smbd/service_task.c
+++ b/source4/smbd/service_task.c
@@ -34,7 +34,7 @@ void task_server_terminate(struct task_server *task, const char *reason, bool fa
const struct model_ops *model_ops = task->model_ops;
DEBUG(0,("task_server_terminate: [%s]\n", reason));
- if (fatal) {
+ if (fatal && task->msg_ctx != NULL) {
struct dcerpc_binding_handle *irpc_handle;
struct samba_terminate r;