Commit 1e924a43 authored by Rémi Duraffort's avatar Rémi Duraffort

Fix a segfault (buffer overflow for win32 only).

(cherry picked from commit e60a9038)
Signed-off-by: default avatarRémi Duraffort <ivoire@videolan.org>
parent 1d3a963a
......@@ -473,7 +473,7 @@ static void Win32AddConnection( access_t *p_access, char *psz_path,
strlcpy( psz_share, psz_parser, sizeof( psz_share ) );
}
sprintf( psz_remote, "\\\\%s\\%s", psz_server, psz_share );
snprintf( psz_remote, sizeof( psz_remote ), "\\\\%s\\%s", psz_server, psz_share );
net_resource.lpRemoteName = psz_remote;
i_result = OurWNetAddConnection2( &net_resource, psz_pwd, psz_user, 0 );
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment