Handle %ls same as %s.

oldstable
Marcus Meissner 2000-11-25 01:19:58 +00:00 committed by Alexandre Julliard
parent b7512e480e
commit e93807c0cb
1 changed files with 3 additions and 0 deletions

View File

@ -245,10 +245,13 @@ DWORD WINAPI FormatMessageA(
if (NULL!=(x=strchr(f,'!'))) {
*x='\0';
fmtstr=HeapAlloc(GetProcessHeap(),0,strlen(f)+2);
/* %ls ? */
if (!strcmp(f,"ls")) f++;
sprintf(fmtstr,"%%%s",f);
f=x+1;
} else {
fmtstr=HeapAlloc(GetProcessHeap(),0,strlen(f)+2);
if (!strcmp(f,"ls")) f++;
sprintf(fmtstr,"%%%s",f);
f+=strlen(f); /*at \0*/
}