mirror of
https://github.com/cesanta/mongoose.git
synced 2026-11-28 20:58:31 +00:00
Bug fix in Win32 mg_mkdir
This commit is contained in:
1 parent
ef9b103a00
commit
d3005df019
1 file changed
+1
-1
+1
-1
@@ -1169,7 +1169,7 @@ static int mg_mkdir(const char *path, int mode) {
|
|||||||
mg_strlcpy(buf, path, sizeof(buf));
|
mg_strlcpy(buf, path, sizeof(buf));
|
||||||
change_slashes_to_backslashes(buf);
|
change_slashes_to_backslashes(buf);
|
||||||
|
|
||||||
(void) MultiByteToWideChar(CP_UTF8, 0, buf, -1, wbuf, sizeof(wbuf));
|
(void) MultiByteToWideChar(CP_UTF8, 0, buf, -1, wbuf, ARRAY_SIZE(wbuf));
|
||||||
|
|
||||||
return CreateDirectoryW(wbuf, NULL) ? 0 : -1;
|
return CreateDirectoryW(wbuf, NULL) ? 0 : -1;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user