php/php-src — pull request #478 by pilif (2013-10-02 06:39:04+00:00)
Title: fix bug 65667

This PR is a fix for [bug 65667](https://bugs.php.net/bug.php?id=65667)

the idea behind ftp_nb_get is for it to be followed by multiple calls
to ftp_nb_continue in order to download a file piece-by-piece.

As such, it's unwise to close the stream used to write the downloaded
data to when the file hasn't been completely downloaded within the first
call to ftp_nb_get.

This regression was added in a93a462dcefd62e07963dd2da506fbb3409c88b5
and this patch restores the behavior that was seen pre-patch.