diff options
author | Andreas Fischer <bantu@phpbb.com> | 2011-01-17 22:31:59 +0100 |
---|---|---|
committer | Andreas Fischer <bantu@phpbb.com> | 2011-01-17 22:34:39 +0100 |
commit | 19931713db35307461bfe0784f32526d24caf912 (patch) | |
tree | 309bbb3cc7d366103d7afefd32ced044056675bb /phpBB/includes/functions_download.php | |
parent | 0f88b847fcee1d4b4745eb5ba4fec72c01e4dc5b (diff) | |
download | forums-19931713db35307461bfe0784f32526d24caf912.tar forums-19931713db35307461bfe0784f32526d24caf912.tar.gz forums-19931713db35307461bfe0784f32526d24caf912.tar.bz2 forums-19931713db35307461bfe0784f32526d24caf912.tar.xz forums-19931713db35307461bfe0784f32526d24caf912.zip |
[ticket/9790] Always call file_gc(false) before sending the file.
This also unloads the cache before the file is send.
PHPBB3-9790
Diffstat (limited to 'phpBB/includes/functions_download.php')
-rw-r--r-- | phpBB/includes/functions_download.php | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/phpBB/includes/functions_download.php b/phpBB/includes/functions_download.php index 390ae7a5a4..80b71f1301 100644 --- a/phpBB/includes/functions_download.php +++ b/phpBB/includes/functions_download.php @@ -224,8 +224,8 @@ function send_file_to_browser($attachment, $upload_dir, $category) header("Content-Length: $size"); } - // Close the db connection before sending the file - $db->sql_close(); + // Close the db connection before sending the file etc. + file_gc(false); if (!set_modified_headers($attachment['filetime'], $user->browser)) { @@ -259,7 +259,8 @@ function send_file_to_browser($attachment, $upload_dir, $category) flush(); } - file_gc(); + + exit; } /** |