X-Git-Url: https://git.m6w6.name/?p=m6w6%2Fext-http;a=blobdiff_plain;f=http_deflatestream_object.c;h=c3c80458685d9ce880d961b789cf8d450163be18;hp=01e8ae2c8e7058afb7aacfb972909bd7b1515d01;hb=4a81005f234436f91620fb43d5543912625544cb;hpb=8e6cf53b544342e1eaf0ec4f530e32852120294a diff --git a/http_deflatestream_object.c b/http_deflatestream_object.c index 01e8ae2..c3c8045 100644 --- a/http_deflatestream_object.c +++ b/http_deflatestream_object.c @@ -6,7 +6,7 @@ | modification, are permitted provided that the conditions mentioned | | in the accompanying LICENSE file are met. | +--------------------------------------------------------------------+ - | Copyright (c) 2004-2007, Michael Wallner | + | Copyright (c) 2004-2010, Michael Wallner | +--------------------------------------------------------------------+ */ @@ -242,8 +242,10 @@ PHP_METHOD(HttpDeflateStream, flush) STR_FREE(encoded); updated_len += encoded_len; RETURN_STRINGL(updated, updated_len, 0); - } else { + } else if (encoded) { RETVAL_STRINGL(encoded, encoded_len, 0); + } else { + RETVAL_NULL(); } } else { RETVAL_FALSE;