@@ -84,7 +84,7 @@ static char *ini_include = NULL;
84
84
/*
85
85
* Please keep the same order as in fpm_conf.h and in php-fpm.conf.in
86
86
*/
87
- static struct ini_value_parser_s ini_fpm_global_options [] = {
87
+ static const struct ini_value_parser_s ini_fpm_global_options [] = {
88
88
{ "pid" , & fpm_conf_set_string , GO (pid_file ) },
89
89
{ "error_log" , & fpm_conf_set_string , GO (error_log ) },
90
90
#ifdef HAVE_SYSLOG_H
@@ -112,7 +112,7 @@ static struct ini_value_parser_s ini_fpm_global_options[] = {
112
112
/*
113
113
* Please keep the same order as in fpm_conf.h and in php-fpm.conf.in
114
114
*/
115
- static struct ini_value_parser_s ini_fpm_pool_options [] = {
115
+ static const struct ini_value_parser_s ini_fpm_pool_options [] = {
116
116
{ "prefix" , & fpm_conf_set_string , WPO (prefix ) },
117
117
{ "user" , & fpm_conf_set_string , WPO (user ) },
118
118
{ "group" , & fpm_conf_set_string , WPO (group ) },
@@ -1183,11 +1183,10 @@ static int fpm_conf_process_all_pools(void)
1183
1183
/* env[], php_value[], php_admin_values[] */
1184
1184
if (!wp -> config -> chroot ) {
1185
1185
struct key_value_s * kv ;
1186
- char * options [] = FPM_PHP_INI_TO_EXPAND ;
1187
- char * * p ;
1186
+ static const char * const options [] = FPM_PHP_INI_TO_EXPAND ;
1188
1187
1189
1188
for (kv = wp -> config -> php_values ; kv ; kv = kv -> next ) {
1190
- for (p = options ; * p ; p ++ ) {
1189
+ for (const char * const * p = options ; * p ; p ++ ) {
1191
1190
if (!strcasecmp (kv -> key , * p )) {
1192
1191
fpm_evaluate_full_path (& kv -> value , wp , NULL , 0 );
1193
1192
}
@@ -1197,7 +1196,7 @@ static int fpm_conf_process_all_pools(void)
1197
1196
if (!strcasecmp (kv -> key , "error_log" ) && !strcasecmp (kv -> value , "syslog" )) {
1198
1197
continue ;
1199
1198
}
1200
- for (p = options ; * p ; p ++ ) {
1199
+ for (const char * const * p = options ; * p ; p ++ ) {
1201
1200
if (!strcasecmp (kv -> key , * p )) {
1202
1201
fpm_evaluate_full_path (& kv -> value , wp , NULL , 0 );
1203
1202
}
@@ -1464,7 +1463,7 @@ static void fpm_conf_ini_parser_section(zval *section, void *arg) /* {{{ */
1464
1463
1465
1464
static void fpm_conf_ini_parser_entry (zval * name , zval * value , void * arg ) /* {{{ */
1466
1465
{
1467
- struct ini_value_parser_s * parser ;
1466
+ const struct ini_value_parser_s * parser ;
1468
1467
void * config = NULL ;
1469
1468
1470
1469
int * error = (int * )arg ;
0 commit comments