зеркало из https://github.com/github/putty.git
Fix a mistaken use of a format string in logevent().
logevent() doesn't do printf-style formatting (though the logeventf wrapper in ssh.c does), so if you need to format a message, it has to be done separately with dupprintf.
This commit is contained in:
Родитель
6bea4b2502
Коммит
1659cf3f14
|
@ -398,8 +398,10 @@ int WINAPI WinMain(HINSTANCE inst, HINSTANCE prev, LPSTR cmdline, int show)
|
|||
#ifndef UNPROTECT
|
||||
char *error = NULL;
|
||||
if (! setprocessacl(error)) {
|
||||
logevent(NULL, "Could not restrict process ACL: %s",
|
||||
error);
|
||||
char *message = dupprintf("Could not restrict process ACL: %s",
|
||||
error);
|
||||
logevent(NULL, message);
|
||||
sfree(message);
|
||||
sfree(error);
|
||||
}
|
||||
#endif
|
||||
|
|
Загрузка…
Ссылка в новой задаче