projects
/
platform
/
upstream
/
libwebsockets.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
72502e8
)
windows: WCHAR in lws_plat_inet_ntop needs double the final allocation
author
Andy Green
<andy@warmcat.com>
Mon, 5 Sep 2016 07:03:37 +0000
(15:03 +0800)
committer
Andy Green
<andy@warmcat.com>
Mon, 5 Sep 2016 07:03:37 +0000
(15:03 +0800)
https://github.com/warmcat/libwebsockets/issues/619
lib/lws-plat-win.c
patch
|
blob
|
history
diff --git
a/lib/lws-plat-win.c
b/lib/lws-plat-win.c
index
cdf37e9
..
a7e285e
100644
(file)
--- a/
lib/lws-plat-win.c
+++ b/
lib/lws-plat-win.c
@@
-468,7
+468,7
@@
lws_plat_inet_ntop(int af, const void *src, char *dst, int cnt)
DWORD bufferlen = cnt;
BOOL ok = FALSE;
- buffer = lws_malloc(bufferlen);
+ buffer = lws_malloc(bufferlen
* 2
);
if (!buffer) {
lwsl_err("Out of memory\n");
return NULL;