1
0
mirror of https://github.com/falk-werner/webfuse-provider synced 2024-10-27 20:44:10 +00:00

workaround: lws decode base64 size requirements changed

This commit is contained in:
Falk Werner 2019-12-01 13:10:26 +01:00
parent c98a214668
commit 7f29a7987e

View File

@ -17,7 +17,7 @@ static char * wf_impl_fill_buffer(
wf_status * status) wf_status * status)
{ {
*status = WF_GOOD; *status = WF_GOOD;
char * buffer = malloc(count + 1); char * buffer = malloc(count + 4); // FixMe: lws 3.2.0 needs more buffer to decode (bug?)
if ((NULL != buffer) && (0 < count)) if ((NULL != buffer) && (0 < count))
{ {
@ -27,7 +27,7 @@ static char * wf_impl_fill_buffer(
} }
else if (0 == strcmp("base64", format)) else if (0 == strcmp("base64", format))
{ {
lws_b64_decode_string(data, buffer, count + 1); lws_b64_decode_string(data, buffer, count + 4);
} }
else else
{ {