|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
Patch system_4095_bytes.patch for Program Execution Bug #79410Patch version 2020-03-25 08:23 UTC Return to Bug #79410 | Download this patchThis patch renders other patches obsolete Obsolete patches: Patch Revisions:Developer: cschneid@php.net
diff --git a/ext/standard/exec.c b/ext/standard/exec.c
index cdf983787b..3b0e0a034f 100644
--- a/ext/standard/exec.c
+++ b/ext/standard/exec.c
@@ -157,6 +157,13 @@ PHPAPI int php_exec(int type, char *cmd, zval *array, zval *return_value)
b = buf;
}
if (bufl) {
+ /* output remaining data in buffer */
+ if (type == 1 && buf != b) {
+ PHPWRITE(buf, bufl);
+ if (php_output_get_level() < 1) {
+ sapi_flush();
+ }
+ }
/* strip trailing whitespaces if we have not done so already */
if ((type == 2 && buf != b) || type != 2) {
l = bufl;
|
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Oct 24 23:00:01 2025 UTC |