diff --git a/programs/start/start.c b/programs/start/start.c index e3071a3a09a..4b31e07dfee 100644 --- a/programs/start/start.c +++ b/programs/start/start.c @@ -280,7 +280,7 @@ static BOOL search_path(const WCHAR *firstParam, WCHAR **full_path) GetFullPathNameW(temp, MAX_PATH, thisDir, NULL); /* 1. If extension supplied, see if that file exists */ - lstrcatW(thisDir, L"\\"); + if (thisDir[lstrlenW(thisDir) - 1] != '\\') lstrcatW(thisDir, L"\\"); lstrcatW(thisDir, stemofsearch); pos = &thisDir[lstrlenW(thisDir)]; /* Pos = end of name */