1
0
mirror of https://github.com/Tha14/toxic.git synced 2024-11-13 01:13:02 +01:00
This commit is contained in:
Jfreegman 2013-10-25 00:33:00 -04:00
parent 3f7e60eaf4
commit ae7087e760

View File

@ -63,7 +63,7 @@ uint8_t *wcs_to_char(wchar_t *string)
size_t len = wcstombs(NULL, string, 0);
if (len != (size_t) -1) {
ret = malloc(len+1);
ret = malloc(++len);
if (ret != NULL)
wcstombs(ret, string, len);