From 76ac3d382daa5b9dc5b1142aba0a8459b630cdd3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20B=C3=BChler?= Date: Thu, 23 May 2013 17:45:37 +0200 Subject: [PATCH 1/3] clear environment after request end --- fastcgi.c | 1 + 1 file changed, 1 insertion(+) diff --git a/fastcgi.c b/fastcgi.c index 4220ed2..4091909 100644 --- a/fastcgi.c +++ b/fastcgi.c @@ -801,6 +801,7 @@ void fastcgi_end_request(fastcgi_connection *fcon, gint32 appStatus, enum FCGI_P if (0 == fcon->requestID) return; stream_send_end_request(&fcon->write_queue, fcon->requestID, appStatus, status); fcon->requestID = 0; + fastcgi_connection_environ_clear(fcon); if (!had_data) write_queue(fcon); } From b2d707796e08714e3a5d013ad73dcd115816164d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20B=C3=BChler?= Date: Thu, 23 May 2013 17:45:57 +0200 Subject: [PATCH 2/3] close stdin after writing request body --- fcgi-cgi.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/fcgi-cgi.c b/fcgi-cgi.c index 31fd27c..b00188b 100644 --- a/fcgi-cgi.c +++ b/fcgi-cgi.c @@ -460,7 +460,11 @@ static void fcgi_cgi_received_stdin(fastcgi_connection *fcon, GByteArray *data) if (data) g_byte_array_free(data, TRUE); return; } - fastcgi_queue_append_bytearray(&cld->write_queue, data); + if (NULL != data) { + fastcgi_queue_append_bytearray(&cld->write_queue, data); + } else { + cld->write_queue.closed = TRUE; + } write_queue(cld); /* if we don't call this we have to check the write-queue length */ } From f214917c92c3f9f14e66597bbdbb48fe59cfd6f2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20B=C3=BChler?= Date: Thu, 23 May 2013 17:46:46 +0200 Subject: [PATCH 3/3] Release as 0.2.1 --- CMakeLists.txt | 2 +- configure.ac | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 303230e..076de21 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -22,7 +22,7 @@ MACRO(ADD_TARGET_PROPERTIES _target _name _properties) ENDMACRO(ADD_TARGET_PROPERTIES) PROJECT(fcgi-cgi C) -SET(PACKAGE_VERSION 0.2.0) +SET(PACKAGE_VERSION 0.2.1) IF("${CMAKE_BUILD_TYPE}" STREQUAL "") SET(CMAKE_BUILD_TYPE RelWithDebInfo CACHE STRING "Choose the type of build, options are: None(CMAKE_CXX_FLAGS or CMAKE_C_FLAGS used) Debug Release RelWithDebInfo MinSizeRel." FORCE) ENDIF("${CMAKE_BUILD_TYPE}" STREQUAL "") diff --git a/configure.ac b/configure.ac index 41073c2..17595a0 100644 --- a/configure.ac +++ b/configure.ac @@ -2,7 +2,7 @@ # Process this file with autoconf to produce a configure script. AC_PREREQ([2.63]) -AC_INIT([fcgi-cgi], [0.2.0], [lighttpd@stbuehler.de]) +AC_INIT([fcgi-cgi], [0.2.1], [lighttpd@stbuehler.de]) AC_CONFIG_SRCDIR([fcgi-cgi.c]) AC_CONFIG_HEADERS([config.h])