prevent buffer overflow, LoadString accepts the size of the buffer in TCHARs, not in bytes!

svn path=/trunk/; revision=14996
This commit is contained in:
Thomas Bluemel 2005-05-05 12:25:40 +00:00
parent e85ca23849
commit 74d7b0c5f4

View file

@ -316,7 +316,7 @@ INT cmd_mkdir (LPTSTR cmd, LPTSTR param)
if (!dir)
{
LoadString( GetModuleHandle(NULL), STRING_ERROR_REQ_PARAM_MISSING, (LPTSTR) szMsg,sizeof(szMsg));
LoadString( GetModuleHandle(NULL), STRING_ERROR_REQ_PARAM_MISSING, szMsg, RC_STRING_MAX_SIZE);
ConErrPrintf (szMsg);
return 1;
}