Thanks Scott, it helps to save files before quitting ;-)

Here is the updated patch.


Ilia Alshanetsky

Index: ext/curl/interface.c
===================================================================
RCS file: /repository/php-src/ext/curl/interface.c,v
retrieving revision 1.62.2.14.2.57
diff -u -p -a -d -r1.62.2.14.2.57 interface.c
--- ext/curl/interface.c        15 Jun 2009 12:38:11 -0000      1.62.2.14.2.57
+++ ext/curl/interface.c        26 Jun 2009 23:57:30 -0000
@@ -2093,6 +2093,11 @@ static void _php_curl_close_ex(php_curl 
                efree(ch->header.str);
        }
 
+       /* flush the file handle, so any remaining data is synched to disk */
+       if (ch->handlers->write->method == PHP_CURL_FILE && 
ch->handlers->write->fp) {
+               fflush(ch->handlers->write->fp);
+       }
+
        efree(ch->handlers->write);
        efree(ch->handlers->write_header);
        efree(ch->handlers->read);



On 26-Jun-09, at 7:55 PM, Scott MacVicar wrote:

You have an assignment instead of a comparison there.

Scott
On 27 Jun 2009, at 00:52, Ilia Alshanetsky wrote:

<curl.txt>



-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to