summaryrefslogtreecommitdiff
path: root/sapi
diff options
context:
space:
mode:
Diffstat (limited to 'sapi')
-rw-r--r--sapi/fpm/fpm/fpm_main.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sapi/fpm/fpm/fpm_main.c b/sapi/fpm/fpm/fpm_main.c
index adc3f5b65a..ba6382ca73 100644
--- a/sapi/fpm/fpm/fpm_main.c
+++ b/sapi/fpm/fpm/fpm_main.c
@@ -670,9 +670,10 @@ void sapi_cgi_log_fastcgi(int level, char *message, size_t len)
*/
if (CGIG(fcgi_logging) && request && message && len > 0) {
char *buf = malloc(len + 2);
+ ssize_t ret = 0;
memcpy(buf, message, len);
memcpy(buf + len, "\n", sizeof("\n"));
- ssize_t ret = fcgi_write(request, FCGI_STDERR, buf, len+1);
+ ret = fcgi_write(request, FCGI_STDERR, buf, len+1);
free(buf);
if (ret <= 0) {
php_handle_aborted_connection();