Commit 049d918
authored
fix(cli): repair dead PHP-binary dash-prefix guard in push_out_hosts.php (#7148)
* fix(cli): repair dead PHP-binary dash-prefix guard in push_out_hosts.php
The dash-prefix safety check in cli/push_out_hosts.php:55 referenced
$binary, which is never defined in this scope; $php_binary is the
real local set on line 39. Under PHP 8 the strpos(null, ...) call
returns false and the guard is dead, so a path_php_binary value
starting with a dash slips through to the passthru() command line.
The branch also returned 1 from top-level script context where exit(1)
is required to propagate the failure to the caller. Same line fixes
the "en empty" log typo.
Signed-off-by: Thomas Vincent <thomasvincent@gmail.com>
* test(security): refresh baselines after push_out_hosts line shift
The new dash-prefix guard added one line below the empty-binary
check; the passthru() sink in the same file shifted by one and the
sink_inventory pin needs to track it. Mechanical regeneration.
Signed-off-by: Thomas Vincent <thomasvincent@gmail.com>
---------
Signed-off-by: Thomas Vincent <thomasvincent@gmail.com>1 parent 3048c6f commit 049d918
3 files changed
Lines changed: 7 additions & 6 deletions
File tree
- cli
- tests/security/baselines
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
47 | 47 | | |
48 | 48 | | |
49 | 49 | | |
50 | | - | |
| 50 | + | |
51 | 51 | | |
52 | 52 | | |
53 | 53 | | |
54 | 54 | | |
55 | | - | |
56 | | - | |
57 | | - | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
58 | 59 | | |
59 | 60 | | |
60 | 61 | | |
| |||
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
| 10 | + | |
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
9 | | - | |
| 9 | + | |
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
| |||
0 commit comments