From: Ralph Boehme Date: Fri, 17 Nov 2017 07:13:10 +0000 (+0100) Subject: s4/torture: let write_stream() deal with stream=NULL X-Git-Tag: talloc-2.1.11~343 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=ac880848a905a3840b69af2cb1d842d307401a07;p=thirdparty%2Fsamba.git s4/torture: let write_stream() deal with stream=NULL Bug: https://bugzilla.samba.org/show_bug.cgi?id=13155 Signed-off-by: Ralph Boehme Reviewed-by: Jeremy Allison --- diff --git a/source4/torture/vfs/fruit.c b/source4/torture/vfs/fruit.c index 3c3810ceaa6..471a755a40d 100644 --- a/source4/torture/vfs/fruit.c +++ b/source4/torture/vfs/fruit.c @@ -1140,7 +1140,7 @@ static bool write_stream(struct smb2_tree *tree, NTSTATUS status; const char *full_name; - full_name = talloc_asprintf(mem_ctx, "%s%s", fname, sname); + full_name = talloc_asprintf(mem_ctx, "%s%s", fname, sname ? sname : ""); if (full_name == NULL) { torture_comment(tctx, "talloc_asprintf error\n"); return false;