Skip to content
Snippets Groups Projects
Commit 7b32a327 authored by Elizabeth Figura's avatar Elizabeth Figura Committed by Alexandre Julliard
Browse files

server: Allocate enough space for the backslash in dup_nt_name() (Valgrind).

parent 6fe37b46
No related branches found
No related tags found
No related merge requests found
......@@ -1867,7 +1867,7 @@ static WCHAR *dup_nt_name( struct fd *root, struct unicode_str name, data_size_t
name.str++;
name.len -= sizeof(WCHAR);
}
if ((ret = malloc( retlen + name.len + 1 )))
if ((ret = malloc( retlen + name.len + sizeof(WCHAR) )))
{
memcpy( ret, root->nt_name, root->nt_namelen );
if (name.len && name.str[0] != '\\' &&
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment