Commit 01d608aa authored by Wandenberg Peixoto's avatar Wandenberg Peixoto

fix bug on ngx_http_push_stream_get_formatted_chunk function on 32bits OS

parent a497d59a
...@@ -1235,7 +1235,7 @@ ngx_http_push_stream_get_formatted_chunk(const u_char *text, off_t len, ngx_pool ...@@ -1235,7 +1235,7 @@ ngx_http_push_stream_get_formatted_chunk(const u_char *text, off_t len, ngx_pool
/* the "0000000000000000" is 64-bit hexadimal string */ /* the "0000000000000000" is 64-bit hexadimal string */
chunk = ngx_http_push_stream_create_str(temp_pool, sizeof("0000000000000000" CRLF CRLF CRLF) + len); chunk = ngx_http_push_stream_create_str(temp_pool, sizeof("0000000000000000" CRLF CRLF CRLF) + len);
if (chunk != NULL) { if (chunk != NULL) {
ngx_sprintf(chunk->data, "%xO" CRLF "%*s" CRLF CRLF, len + sizeof(CRLF) - 1, len, text); ngx_sprintf(chunk->data, "%xO" CRLF "%*s" CRLF CRLF, len + sizeof(CRLF) - 1, (size_t) len, text);
chunk->len = ngx_strlen(chunk->data); chunk->len = ngx_strlen(chunk->data);
} }
return chunk; return chunk;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment