" -t -D DUMP_MODULES : show all loaded modules ");
ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -M : a synonym for -t -D DUMP_MODULES");
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
+ " -t -D DUMP_INCLUDES: show all included configuration files");
ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -t : run syntax check for config files");
ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
module **mod;
const char *opt_arg;
APR_OPTIONAL_FN_TYPE(ap_signal_server) *signal_server;
+ int rc = OK;
AP_MONCONTROL(0); /* turn off profiling of startup */
/* Setting -D DUMP_MODULES is equivalent to setting -M */
else if (strcmp(opt_arg, "DUMP_MODULES") == 0)
ap_run_mode = AP_SQ_RM_CONFIG_DUMP;
+ /* Setting -D DUMP_INCLUDES is a type of configuration dump */
+ else if (strcmp(opt_arg, "DUMP_INCLUDES") == 0)
+ ap_run_mode = AP_SQ_RM_CONFIG_DUMP;
break;
case 'e':
apr_pool_destroy(ptemp);
- for (;;) {
+ do {
ap_main_state = AP_SQ_MS_DESTROY_CONFIG;
apr_hook_deregister_all();
apr_pool_clear(pconf);
ap_run_optional_fn_retrieve();
ap_main_state = AP_SQ_MS_RUN_MPM;
- if (ap_run_mpm(pconf, plog, ap_server_conf) != OK)
- break;
+ rc = ap_run_mpm(pconf, plog, ap_server_conf);
apr_pool_lock(pconf, 0);
- }
- apr_pool_lock(pconf, 0);
- destroy_and_exit_process(process, 0);
+ } while (rc == OK);
+
+ if (rc == DONE) {
+ rc = OK;
+ }
+ else if (rc != OK) {
+ ap_log_error(APLOG_MARK, APLOG_EMERG, 0, NULL, APLOGNO(02818)
+ "MPM run failed, exiting");
+ }
+ destroy_and_exit_process(process, rc);
- return 0; /* Termination 'ok' */
+ /* NOTREACHED */
+ return !OK;
}
#ifdef AP_USING_AUTOCONF