If we run into the "This is a stream on the root of the share" case,
in old line 409 (new line 417) we "goto done;". If then in old line 1027
(new line 1035) "build_stream_path" fails, "start" is uninitialized.
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Fri Jan 8 05:44:15 CET 2016 on sn-devel-144
uint32_t ucf_flags)
{
struct smb_filename *smb_fname = NULL;
- char *start, *end;
+
+ /*
+ * This looks strange. But we need "start" initialized to "" here but
+ * it can't be a const char *, so 'char *start = "";' does not work.
+ */
+ char cnull = '\0';
+ char *start = &cnull;
+
+ char *end;
char *dirpath = NULL;
char *stream = NULL;
bool component_was_mangled = False;