diff options
| author | jvoisin | 2024-01-26 16:57:29 +0100 |
|---|---|---|
| committer | jvoisin | 2024-01-26 16:57:29 +0100 |
| commit | c505b1c3fb8df3eb9c7b3568c4996d095f1583a6 (patch) | |
| tree | 5b25958be1c06d087bdf1ae616eec745446f4a31 /src/snuffleupagus.c | |
| parent | 8ea689e120c219d854d7c68a5ca52eacc6ef4104 (diff) | |
Bail early in case of invalid config in PHP_RINIT_
Diffstat (limited to 'src/snuffleupagus.c')
| -rw-r--r-- | src/snuffleupagus.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/snuffleupagus.c b/src/snuffleupagus.c index f4ea1d3..21bf66b 100644 --- a/src/snuffleupagus.c +++ b/src/snuffleupagus.c | |||
| @@ -208,8 +208,10 @@ PHP_RINIT_FUNCTION(snuffleupagus) { | |||
| 208 | if (!SPG(allow_broken_configuration)) { | 208 | if (!SPG(allow_broken_configuration)) { |
| 209 | if (SPG(is_config_valid) == SP_CONFIG_INVALID) { | 209 | if (SPG(is_config_valid) == SP_CONFIG_INVALID) { |
| 210 | sp_log_err("config", "Invalid configuration file"); | 210 | sp_log_err("config", "Invalid configuration file"); |
| 211 | return SUCCESS; | ||
| 211 | } else if (SPG(is_config_valid) == SP_CONFIG_NONE) { | 212 | } else if (SPG(is_config_valid) == SP_CONFIG_NONE) { |
| 212 | sp_log_warn("config", "No configuration specified via sp.configuration_file"); | 213 | sp_log_warn("config", "No configuration specified via sp.configuration_file"); |
| 214 | return SUCCESS; | ||
| 213 | } | 215 | } |
| 214 | } | 216 | } |
| 215 | 217 | ||
