1
0
Fork 0
mirror of https://github.com/warmcat/libwebsockets.git synced 2025-03-09 00:00:04 +01:00

coverity 175438: server status plugin: off-by-one if you generate 32KB of content

This commit is contained in:
Andy Green 2017-02-06 10:14:47 +08:00
parent af9ddec2f7
commit cde0371a83

View file

@ -73,7 +73,7 @@ uv_timeout_cb_server_status(uv_timer_t *w
char *p = v->d.buf + LWS_PRE, contents[256], pure[256];
int n, l, first = 1, fd;
l = sizeof(v->d.buf) - LWS_PRE;
l = sizeof(v->d.buf) - LWS_PRE - 1;
n = lws_snprintf(p, l, "{\"i\":");
p += n;