[php-src] Issue #13739: Can `exec` return `false` on php8+?
| From: | staabm | Date: | Sun, 17 Mar 2024 19:40:27 +0000 |
| Subject: | [php-src] Issue #13739: Can `exec` return `false` on php8+? | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-246598@lists.php.net to get a copy of this message | ||
Issue: https://github.com/php/php-src/issues/13739
Author: staabm
### Description
we are wondering whether the [note in the docs](https://www.php.net/manual/en/function.exec.php)
> If command is empty or contains null bytes, exec() now throws a
> [ValueError](https://www.php.net/manual/en/class.valueerror.php). Previously it emitted an
> [E_WARNING](https://www.php.net/manual/en/errorfunc.constants.php#constant.e-warning) and returned
> [false](https://www.php.net/manual/en/reserved.constants.php#constant.false).
means that
exec can no longer return false?
the docs denote a string|false return type, and also [the
stubs](https://github.com/php/php-src/blob/47b6eabe37fcb0cd0dd8608648e1fc075bdb7c73/ext/standard/basic_functions.stub.php#L2718)
declare it.
### PHP Version
8.x
### Operating System
_No response_