file_server: Add a missing no memory check
authorAndreas Schneider <asn@samba.org>
Mon, 11 Jan 2021 15:24:00 +0000 (16:24 +0100)
committerAndrew Bartlett <abartlet@samba.org>
Wed, 28 Apr 2021 03:43:34 +0000 (03:43 +0000)
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
file_server/file_server.c

index 69aabbe3ca1c0885247ced2043cc2620e510aa3e..91c3147734c9b138f2d03bc578249f4255d25997 100644 (file)
@@ -62,6 +62,9 @@ static NTSTATUS s3fs_task_init(struct task_server *task)
        task_server_set_title(task, "task[s3fs_parent]");
 
        smbd_path = talloc_asprintf(task, "%s/smbd", dyn_SBINDIR);
+       if (smbd_path == NULL) {
+               return NT_STATUS_NO_MEMORY;
+       }
        smbd_cmd[0] = smbd_path;
 
        /* the child should be able to call through nss_winbind */