mirror of
https://github.com/zotanmew/nginx-rtmp-module.git
synced 2024-05-19 01:31:09 +02:00
disabled function inlining to escape msvc optimization problem
This commit is contained in:
parent
01c8daf4b4
commit
c4e78b6ea9
|
@ -155,6 +155,13 @@ ngx_rtmp_stat_escape(ngx_http_request_t *r, void *data, size_t len)
|
|||
return new_data;
|
||||
}
|
||||
|
||||
#if (NGX_WIN32)
|
||||
/*
|
||||
* Fix broken MSVC memcpy optimization for 4-byte data
|
||||
* when this function is inlined
|
||||
*/
|
||||
__declspec(noinline)
|
||||
#endif
|
||||
|
||||
static void
|
||||
ngx_rtmp_stat_output(ngx_http_request_t *r, ngx_chain_t ***lll,
|
||||
|
@ -204,15 +211,6 @@ ngx_rtmp_stat_output(ngx_http_request_t *r, ngx_chain_t ***lll,
|
|||
if (escape) {
|
||||
b->last = (u_char *)ngx_escape_html(b->last, data, len);
|
||||
} else {
|
||||
#if (NGX_WIN32)
|
||||
/* fix broken MSVC memcpy optimization for 4-byte data */
|
||||
|
||||
if (len == 4) {
|
||||
*(uint32_t *) b->last = *(uint32_t *) data;
|
||||
b->last += 4;
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
b->last = ngx_cpymem(b->last, data, len);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue