notepad: Improve handling of quoted filenames.

This commit is contained in:
Francois Gouget 2008-06-10 10:20:19 +02:00 committed by Alexandre Julliard
parent d93fa6a1e7
commit 5bc7b784cb
1 changed files with 6 additions and 1 deletions

View File

@ -571,8 +571,13 @@ static void HandleCommandLine(LPWSTR cmdline)
if (cmdline[0] == '"')
{
WCHAR* wc;
cmdline++;
cmdline[lstrlen(cmdline) - 1] = 0;
wc=cmdline;
/* Note: Double-quotes are not allowed in Windows filenames */
while (*wc && *wc != '"') wc++;
/* On Windows notepad ignores further arguments too */
*wc = 0;
}
if (FileExists(cmdline))