r->handler = old_handler;
if (result == DECLINED && r->handler && r->filename) {
- ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_WARNING, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_WARNING, 0, r,
"handler \"%s\" not found for: %s", r->handler, r->filename);
}
*/
if (m->version != MODULE_MAGIC_NUMBER_MAJOR) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"%s: module \"%s\" is not compatible with this "
"version of Apache.", ap_server_argv0, m->name);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Please contact the vendor for the correct version.");
exit(1);
}
dynamic_modules++;
if (dynamic_modules > DYNAMIC_MODULE_LIMIT) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"%s: module \"%s\" could not be loaded, because"
" the dynamic", ap_server_argv0, m->name);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"module limit was reached. Please increase "
"DYNAMIC_MODULE_LIMIT and recompile.");
exit(1);
if (!modp) {
/* Uh-oh, this module doesn't exist */
- ap_log_error(APLOG_MARK, APLOG_ERR|APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0, NULL,
"Cannot remove module %s: not found in module list",
m->name);
return;
sizeof(module *) * (total_modules + DYNAMIC_MODULE_LIMIT + 1));
if (ap_loaded_modules == NULL) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Ouch! Out of memory in ap_setup_prelinked_modules()!");
}
errmsg = ap_build_config(&parms, p, ptemp, conftree);
if (errmsg) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Syntax error in -C/-c directive:" APR_EOL_STR "%s",
errmsg);
exit(1);
parms.override = (RSRC_CONF | OR_ALL) & ~(OR_AUTHCFG | OR_LIMIT);
if (ap_pcfg_openfile(&cfp, p, fname) != APR_SUCCESS) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"%s: could not open document config file %s",
ap_server_argv0, fname);
exit(1);
errmsg = ap_build_config(&parms, p, ptemp, conftree);
if (errmsg != NULL) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Syntax error on line %d of %s:",
parms.err_directive->line_num,
parms.err_directive->filename);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"%s", errmsg);
exit(1);
}
errmsg = ap_walk_config(conftree, &parms, s->lookup_defaults);
if (errmsg) {
- ap_log_perror(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, p,
+ ap_log_perror(APLOG_MARK, APLOG_STARTUP, 0, p,
"Syntax error on line %d of %s:",
parms.err_directive->line_num,
parms.err_directive->filename);
- ap_log_perror(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, p,
+ ap_log_perror(APLOG_MARK, APLOG_STARTUP, 0, p,
"%s", errmsg);
exit(1);
}
ap_cfg_closefile(f);
if (errmsg) {
- ap_log_rerror(APLOG_MARK, APLOG_ALERT|APLOG_NOERRNO, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_ALERT, 0, r,
"%s: %s", filename, errmsg);
return HTTP_INTERNAL_SERVER_ERROR;
}
APR_FILEPATH_TRUENAME, cmd->pool) != APR_SUCCESS
|| !ap_is_directory(cmd->pool, arg)) {
if (cmd->server->is_virtual) {
- ap_log_perror(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0,
+ ap_log_perror(APLOG_MARK, APLOG_STARTUP, 0,
cmd->pool,
"Warning: DocumentRoot [%s] does not exist",
arg);
/* The entry should be ignored if it is a full URL for a 401 error */
if (error_number == 401 && what == REMOTE_PATH) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, cmd->server,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, cmd->server,
"cannot use a full URL in a 401 ErrorDocument "
"directive --- ignoring!");
}
static const char *no_set_limit(cmd_parms *cmd, void *conf_,
const char *arg, const char *arg2)
{
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0, cmd->server,
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0, cmd->server,
"%s not supported on this platform", cmd->cmd->name);
return NULL;
return HTTP_FORBIDDEN;
}
if (!r->uri || ((r->uri[0] != '/') && strcmp(r->uri, "*"))) {
- ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r,
"Invalid URI in request %s", r->the_request);
return HTTP_BAD_REQUEST;
}
if (r->method_number == M_GET || r->method_number == M_POST) {
if (r->finfo.filetype == 0) {
- ap_log_rerror(APLOG_MARK, APLOG_ERR|APLOG_NOERRNO, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r,
"File does not exist: %s", r->filename);
return HTTP_NOT_FOUND;
}
r->path_info && *r->path_info)
{
/* default to reject */
- ap_log_rerror(APLOG_MARK, APLOG_ERR|APLOG_NOERRNO, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r,
"File does not exist: %s",
apr_pstrcat(r->pool, r->filename, r->path_info, NULL));
return HTTP_NOT_FOUND;
}
else { /* unusual method (not GET or POST) */
if (r->method_number == M_INVALID) {
- ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r,
"Invalid method in request %s", r->the_request);
return HTTP_NOT_IMPLEMENTED;
}
* that may screw up scripts written to do something
* based on the last modification time of the pid file.
*/
- ap_log_perror(APLOG_MARK, APLOG_NOERRNO|APLOG_WARNING, 0, p,
+ ap_log_perror(APLOG_MARK, APLOG_WARNING, 0, p,
apr_psprintf(p, "pid file %s overwritten -- Unclean "
"shutdown of previous Apache run?",
fname));
!= APR_SUCCESS) {
ap_log_error(APLOG_MARK, APLOG_ERR, rv, NULL,
"could not create %s", fname);
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0, NULL,
"%s: could not log pid to file %s",
ap_server_argv0, fname);
exit(1);
char time_str[APR_CTIME_LEN];
apr_ctime(time_str, apr_time_now());
- ap_log_error(APLOG_MARK, APLOG_CRIT | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_CRIT, 0, NULL,
"[%s] file %s, line %d, assertion \"%s\" failed",
time_str, szFile, nLine, szExp);
#if defined(WIN32)
!= APR_SUCCESS)) {
char buf[120];
/* Something bad happened, give up and go away. */
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"piped_log_spawn: unable to setup child process '%s': %s",
pl->program, apr_strerror(status, buf, sizeof(buf)));
rc = -1;
/* what can we do? This could be the error log we're having
* problems opening up... */
char buf[120];
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"piped_log_maintenance: unable to respawn '%s': %s",
pl->program, apr_strerror(stats, buf, sizeof(buf)));
}
pad[i] = '\0';
#ifdef SHARED_CORE
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL ,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL ,
"Usage: %s [-R directory] [-D name] [-d directory] [-f file]",
bin);
#else
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Usage: %s [-D name] [-d directory] [-f file]", bin);
#endif
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" %s [-C \"directive\"] [-c \"directive\"]", pad);
#ifdef WIN32
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" %s [-k start|restart|stop|shutdown]", pad);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" %s [-k install|config|uninstall] [-n service_name]",
pad);
#endif
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" %s [-v] [-V] [-h] [-l] [-L] [-t] [-T]", pad);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Options:");
#ifdef SHARED_CORE
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -R directory : specify an alternate location for "
"shared object files");
#endif
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -D name : define a name for use in "
"<IfDefine name> directives");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -d directory : specify an alternate initial "
"ServerRoot");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -f file : specify an alternate ServerConfigFile");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -C \"directive\" : process directive before reading "
"config files");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -c \"directive\" : process directive after reading "
"config files");
#ifdef WIN32
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -n name : set service name and use its "
"ServerConfigFile");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -k start : tell Apache to start");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -k restart : tell running Apache to do a graceful "
"restart");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -k stop|shutdown : tell running Apache to shutdown");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -k install : install an Apache service");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -k config : change startup Options of an Apache "
"service");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -k uninstall : uninstall an Apache service");
#endif
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -e level : show startup errors of level "
"(see LogLevel)");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -E file : log startup errors to file");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -v : show version number");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -V : show compile settings");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -h : list available command line options "
"(this page)");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -l : list compiled in modules");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -L : list available configuration "
"directives");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -t -D DUMP_VHOSTS : show parsed settings (currently only "
"vhost settings)");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -t : run syntax check for config files "
"(with docroot check)");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" -T : run syntax check for config files "
"(without docroot check)");
}
server_conf = ap_read_config(process, ptemp, confname, &ap_conftree);
if (ap_run_pre_config(pconf, plog, ptemp) != OK) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP |APLOG_ERR| APLOG_NOERRNO, 0,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP |APLOG_ERR, 0,
NULL, "Pre-configuration failed\n");
destroy_and_exit_process(process, 1);
}
ap_fini_vhost_config(pconf, server_conf);
apr_sort_hooks();
if (configtestonly) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Syntax OK\n");
destroy_and_exit_process(process, 0);
}
}
if ( ap_run_post_config(pconf, plog, ptemp, server_conf) != OK) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP |APLOG_ERR| APLOG_NOERRNO, 0,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP |APLOG_ERR, 0,
NULL, "Configuration Failed\n");
destroy_and_exit_process(process, 1);
}
ap_server_root = def_server_root;
server_conf = ap_read_config(process, ptemp, confname, &ap_conftree);
if (ap_run_pre_config(pconf, plog, ptemp) != OK) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP |APLOG_ERR| APLOG_NOERRNO,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP |APLOG_ERR,
0, NULL, "Pre-configuration failed\n");
destroy_and_exit_process(process, 1);
}
apr_sort_hooks();
apr_pool_clear(plog);
if (ap_run_open_logs(pconf, plog, ptemp, server_conf) != OK) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP |APLOG_ERR| APLOG_NOERRNO,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP |APLOG_ERR,
0, NULL, "Unable to open logs\n");
destroy_and_exit_process(process, 1);
}
if (ap_run_post_config(pconf, plog, ptemp, server_conf) != OK) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP |APLOG_ERR | APLOG_NOERRNO,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP |APLOG_ERR,
0, NULL, "Configuration Failed\n");
destroy_and_exit_process(process, 1);
}
(void)apr_os_sock_get(&csd, sock);
if (csd >= FD_SETSIZE) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_WARNING, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_WARNING, 0, NULL,
"filedescriptor (%u) larger than FD_SETSIZE (%u) "
"found, you probably need to rebuild Apache with a "
"larger FD_SETSIZE", csd, FD_SETSIZE);
apr_bucket_alloc_destroy(bucket_alloc);
- ap_log_error(APLOG_MARK, APLOG_NOTICE | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, NULL,
"worker_thread %ld exiting", find_thread(NULL));
apr_thread_mutex_lock(worker_thread_count_mutex);
if (!restart_pending && !shutdown_pending) {
int slot = (int)data;
make_worker(slot);
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_INFO, 0, NULL,
"spawning a new worker thread in slot %d", slot);
}
}
* scoreboard. Somehow we don't know about this
* child.
*/
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_WARNING, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_WARNING, 0, ap_server_conf,
"long lost child came home! (pid %ld)", pid.pid);
}
}
if ((num_listening_sockets = ap_setup_listeners(ap_server_conf)) < 1) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ALERT, 0, s,
+ ap_log_error(APLOG_MARK, APLOG_ALERT, 0, s,
"no listening sockets available, shutting down");
return 1;
}
/*
* record that we've entered the world !
*/
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, ap_server_conf,
"%s configured -- resuming normal operations",
ap_get_server_version());
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_INFO, 0, ap_server_conf,
"Server built: %s", ap_get_server_built());
restart_pending = shutdown_pending = 0;
const char *pidfile = NULL;
pidfile = ap_server_root_relative (pconf, ap_pid_fname);
if ( pidfile != NULL && unlink(pidfile) == 0)
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_INFO, 0, ap_server_conf,
"removed PID file %s (pid=%ld)", pidfile,
(long)getpid());
}
if (!child_fatal) { /* already recorded */
/* record the shutdown in the log */
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, ap_server_conf,
"caught SIGTERM, shutting down");
}
signal(SIGHUP, SIG_IGN);
if (is_graceful) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, ap_server_conf,
AP_SIG_GRACEFUL_STRING " received. Doing graceful restart");
}
else {
*/
ap_reclaim_child_processes(1); /* Start with SIGTERM */
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, ap_server_conf,
"SIGHUP received. Attempting to restart");
}
ap_threads_to_start = atoi(arg);
if (ap_threads_to_start < 0) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"StartThreads set to a value less than 0, reset to 1");
ap_threads_to_start = 1;
}
min_spare_threads = atoi(arg);
if (min_spare_threads <= 0) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: detected MinSpareThreads set to non-positive.");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Resetting to 1 to avoid almost certain Apache failure.");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Please read the documentation.");
min_spare_threads = 1;
}
ap_thread_limit = atoi(arg);
if (ap_thread_limit > HARD_THREAD_LIMIT) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: MaxClients of %d exceeds compile time limit "
"of %d servers,", ap_thread_limit, HARD_THREAD_LIMIT);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" lowering MaxClients to %d. To increase, please "
"see the", HARD_THREAD_LIMIT);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" HARD_THREAD_LIMIT define in server/mpm/beos/mpm_default.h.");
ap_thread_limit = HARD_THREAD_LIMIT;
}
else if (ap_thread_limit < 1) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: Require MaxClients > 0, setting to %d", HARD_THREAD_LIMIT);
ap_thread_limit = HARD_THREAD_LIMIT;
}
ap_max_requests_per_thread = atoi(arg);
if (ap_max_requests_per_thread < 0) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: MaxRequestsPerThread was set below 0"
"reset to 0, but this may not be what you want.");
ap_max_requests_per_thread = 0;
apr_filepath_set(ap_coredump_dir, pconf);
apr_signal(sig, SIG_DFL);
if (ap_my_pid == parent_pid) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE,
0, ap_server_conf,
"seg fault or similar nasty error detected "
"in the parent process");
apr_os_sock_get(&csd, sock);
if (csd >= FD_SETSIZE) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_WARNING, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_WARNING, 0, NULL,
"new file descriptor %d is too large; you probably need "
"to rebuild Apache with a larger FD_SETSIZE "
"(currently %d)",
idle_worker_stack = worker_stack_create(pchild, ap_threads_per_child);
if (idle_worker_stack == NULL) {
- ap_log_error(APLOG_MARK, APLOG_ALERT|APLOG_NOERRNO, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_ALERT, 0, ap_server_conf,
"worker_stack_create() failed");
clean_child_exit(APEXIT_CHILDFATAL);
}
int status = bindprocessor(BINDPROCESS, (int)getpid(),
PROCESSOR_CLASS_ANY);
if (status != OK)
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_WARNING, errno,
+ ap_log_error(APLOG_MARK, APLOG_WARNING, errno,
ap_server_conf,
"processor unbind failed %d", status);
#endif
static int reported = 0;
if (!reported) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0,
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0,
ap_server_conf,
"server reached MaxClients setting, consider"
" raising the MaxClients setting");
free_length = idle_spawn_rate;
}
if (idle_spawn_rate >= 8) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, 0,
+ ap_log_error(APLOG_MARK, APLOG_INFO, 0,
ap_server_conf,
"server seems busy, (you may need "
"to increase StartServers, ThreadsPerChild "
/* Great, we've probably just lost a slot in the
* scoreboard. Somehow we don't know about this child.
*/
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_WARNING, 0,
+ ap_log_error(APLOG_MARK, APLOG_WARNING, 0,
ap_server_conf,
"long lost child came home! (pid %ld)",
(long)pid.pid);
first_server_limit = server_limit;
first_thread_limit = thread_limit;
if (changed_limit_at_restart) {
- ap_log_error(APLOG_MARK, APLOG_WARNING | APLOG_NOERRNO, 0, s,
+ ap_log_error(APLOG_MARK, APLOG_WARNING, 0, s,
"WARNING: Attempt to change ServerLimit or ThreadLimit "
"ignored during restart");
changed_limit_at_restart = 0;
hold_off_on_exponential_spawning = 10;
}
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, ap_server_conf,
"%s configured -- resuming normal operations",
ap_get_server_version());
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_INFO, 0, ap_server_conf,
"Server built: %s", ap_get_server_built());
#ifdef AP_MPM_WANT_SET_ACCEPT_LOCK_MECH
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_DEBUG, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, ap_server_conf,
"AcceptMutex: %s", ap_valid_accept_mutex_string);
#endif
restart_pending = shutdown_pending = 0;
const char *pidfile = NULL;
pidfile = ap_server_root_relative (pconf, ap_pid_fname);
if ( pidfile != NULL && unlink(pidfile) == 0)
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, 0,
+ ap_log_error(APLOG_MARK, APLOG_INFO, 0,
ap_server_conf,
"removed PID file %s (pid=%ld)",
pidfile, (long)getpid());
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0,
ap_server_conf, "caught SIGTERM, shutting down");
}
return 1;
ap_scoreboard_image->global->running_generation = ap_my_generation;
if (is_graceful) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, ap_server_conf,
AP_SIG_GRACEFUL_STRING " received. Doing graceful restart");
/* wake up the children...time to die. But we'll have more soon */
ap_mpm_pod_killpg(pod, ap_daemons_limit, TRUE);
ap_mpm_pod_killpg(pod, ap_daemons_limit, FALSE);
ap_reclaim_child_processes(1); /* Start with SIGTERM */
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, ap_server_conf,
"SIGHUP received. Attempting to restart");
}
ap_server_conf = s;
if ((num_listensocks = ap_setup_listeners(ap_server_conf)) < 1) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ALERT|APLOG_STARTUP, 0,
+ ap_log_error(APLOG_MARK, APLOG_ALERT|APLOG_STARTUP, 0,
NULL, "no listening sockets available, shutting down");
return DONE;
}
min_spare_threads = atoi(arg);
if (min_spare_threads <= 0) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: detected MinSpareThreads set to non-positive.");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Resetting to 1 to avoid almost certain Apache failure.");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Please read the documentation.");
min_spare_threads = 1;
}
* sure that it gets set before MaxClients in the pre_config stage. */
max_clients = atoi(arg);
if (max_clients < ap_threads_per_child) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: MaxClients (%d) must be at least as large",
max_clients);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" large as ThreadsPerChild (%d). Automatically",
ap_threads_per_child);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" increasing MaxClients to %d.",
ap_threads_per_child);
max_clients = ap_threads_per_child;
}
ap_daemons_limit = max_clients / ap_threads_per_child;
if ((max_clients > 0) && (max_clients % ap_threads_per_child)) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: MaxClients (%d) is not an integer multiple",
max_clients);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" of ThreadsPerChild (%d), lowering MaxClients to %d",
ap_threads_per_child,
ap_daemons_limit * ap_threads_per_child);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" for a maximum of %d child processes,",
ap_daemons_limit);
max_clients = ap_daemons_limit * ap_threads_per_child;
}
if (ap_daemons_limit > server_limit) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: MaxClients of %d would require %d servers,",
max_clients, ap_daemons_limit);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" and would exceed the ServerLimit value of %d.",
server_limit);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" Automatically lowering MaxClients to %d. To increase,",
server_limit);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" please see the ServerLimit directive.");
ap_daemons_limit = server_limit;
}
else if (ap_daemons_limit < 1) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: Require MaxClients > 0, setting to 1");
ap_daemons_limit = 1;
}
ap_threads_per_child = atoi(arg);
if (ap_threads_per_child > thread_limit) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: ThreadsPerChild of %d exceeds ThreadLimit "
"value of %d", ap_threads_per_child,
thread_limit);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"threads, lowering ThreadsPerChild to %d. To increase, please"
" see the", thread_limit);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" ThreadLimit directive.");
ap_threads_per_child = thread_limit;
}
else if (ap_threads_per_child < 1) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: Require ThreadsPerChild > 0, setting to 1");
ap_threads_per_child = 1;
}
server_limit = tmp_server_limit;
if (server_limit > MAX_SERVER_LIMIT) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: ServerLimit of %d exceeds compile time limit "
"of %d servers,", server_limit, MAX_SERVER_LIMIT);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" lowering ServerLimit to %d.", MAX_SERVER_LIMIT);
server_limit = MAX_SERVER_LIMIT;
}
else if (server_limit < 1) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: Require ServerLimit > 0, setting to 1");
server_limit = 1;
}
thread_limit = tmp_thread_limit;
if (thread_limit > MAX_THREAD_LIMIT) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: ThreadLimit of %d exceeds compile time limit "
"of %d servers,", thread_limit, MAX_THREAD_LIMIT);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" lowering ThreadLimit to %d.", MAX_THREAD_LIMIT);
thread_limit = MAX_THREAD_LIMIT;
}
else if (thread_limit < 1) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: Require ThreadLimit > 0, setting to 1");
thread_limit = 1;
}
}
if (csd >= FD_SETSIZE) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_WARNING, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_WARNING, 0, NULL,
"new file descriptor %d is too large; you probably need "
"to rebuild Apache with a larger FD_SETSIZE "
"(currently %d)",
static int reported = 0;
if (!reported) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0,
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0,
ap_server_conf,
"server reached MaxThreadsPerChild setting, "
"consider raising the MaxThreadsPerChild or "
int status = bindprocessor(BINDPROCESS, (int)getpid(),
PROCESSOR_CLASS_ANY);
if (status != OK) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_WARNING, errno,
+ ap_log_error(APLOG_MARK, APLOG_WARNING, errno,
ap_server_conf, "processor unbind failed %d", status);
}
#endif
* child table. Somehow we don't know about this
* child.
*/
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_WARNING, 0,
+ ap_log_error(APLOG_MARK, APLOG_WARNING, 0,
ap_server_conf,
"long lost child came home! (pid %ld)",
(long)pid.pid);
first_server_limit = server_limit;
first_thread_limit = thread_limit;
if (changed_limit_at_restart) {
- ap_log_error(APLOG_MARK, APLOG_WARNING | APLOG_NOERRNO, 0, s,
+ ap_log_error(APLOG_MARK, APLOG_WARNING, 0, s,
"WARNING: Attempt to change ServerLimit or ThreadLimit "
"ignored during restart");
changed_limit_at_restart = 0;
hold_off_on_exponential_spawning = 10;
}
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, ap_server_conf,
"%s configured -- resuming normal operations",
ap_get_server_version());
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_INFO, 0, ap_server_conf,
"Server built: %s", ap_get_server_built());
#ifdef AP_MPM_WANT_SET_ACCEPT_LOCK_MECH
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_DEBUG, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, ap_server_conf,
"AcceptMutex: %s", ap_valid_accept_mutex_string);
#endif
restart_pending = shutdown_pending = 0;
const char *pidfile = NULL;
pidfile = ap_server_root_relative (pconf, ap_pid_fname);
if (pidfile != NULL && unlink(pidfile) == 0) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, 0,
+ ap_log_error(APLOG_MARK, APLOG_INFO, 0,
ap_server_conf,
"removed PID file %s (pid=%ld)",
pidfile, (long)getpid());
}
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0,
ap_server_conf, "caught SIGTERM, shutting down");
}
return 1;
if (is_graceful) {
char char_of_death = '!';
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0,
ap_server_conf, AP_SIG_GRACEFUL_STRING " received. "
"Doing graceful restart");
"killpg SIGTERM");
}
ap_reclaim_child_processes(1); /* Start with SIGTERM */
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0,
ap_server_conf, "SIGHUP received. Attempting to restart");
}
return 0;
ap_server_conf = s;
if ((num_listensocks = ap_setup_listeners(ap_server_conf)) < 1) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ALERT|APLOG_STARTUP, 0,
+ ap_log_error(APLOG_MARK, APLOG_ALERT|APLOG_STARTUP, 0,
NULL, "no listening sockets available, shutting down");
return DONE;
}
* needs to be passed to another child. */
if (sconf->sd != child_info_table[child_num].sd) {
if (pass_request(r) == -1) {
- ap_log_error(APLOG_MARK, APLOG_ERR | APLOG_NOERRNO, 0,
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0,
ap_server_conf, "Could not pass request to proper "
"child, request will not be honored.");
}
num_daemons = atoi(arg);
if (num_daemons > server_limit) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: NumServers of %d exceeds ServerLimit value "
"of %d servers,", num_daemons, server_limit);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" lowering NumServers to %d. To increase, please "
"see the", server_limit);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" ServerLimit directive.");
num_daemons = server_limit;
}
else if (num_daemons < 1) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: Require NumServers > 0, setting to 1");
num_daemons = 1;
}
threads_to_start = atoi(arg);
if (threads_to_start > thread_limit) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: StartThreads of %d exceeds ThreadLimit value"
" of %d threads,", threads_to_start,
thread_limit);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" lowering StartThreads to %d. To increase, please"
" see the", thread_limit);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" ThreadLimit directive.");
}
else if (threads_to_start < 1) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: Require StartThreads > 0, setting to 1");
threads_to_start = 1;
}
min_spare_threads = atoi(arg);
if (min_spare_threads <= 0) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: detected MinSpareThreads set to non-positive.");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Resetting to 1 to avoid almost certain Apache failure.");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Please read the documentation.");
min_spare_threads = 1;
}
max_spare_threads = atoi(arg);
if (max_spare_threads >= thread_limit) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: detected MinSpareThreads set higher than");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"ThreadLimit. Resetting to %d", thread_limit);
max_spare_threads = thread_limit;
}
max_threads = atoi(arg);
if (max_threads > thread_limit) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: detected MaxThreadsPerChild set higher than");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"ThreadLimit. Resetting to %d", thread_limit);
max_threads = thread_limit;
}
server_limit = tmp_server_limit;
if (server_limit > MAX_SERVER_LIMIT) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: ServerLimit of %d exceeds compile time limit "
"of %d servers,", server_limit, MAX_SERVER_LIMIT);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" lowering ServerLimit to %d.", MAX_SERVER_LIMIT);
server_limit = MAX_SERVER_LIMIT;
}
else if (server_limit < 1) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: Require ServerLimit > 0, setting to 1");
server_limit = 1;
}
thread_limit = tmp_thread_limit;
if (thread_limit > MAX_THREAD_LIMIT) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: ThreadLimit of %d exceeds compile time limit "
"of %d servers,", thread_limit, MAX_THREAD_LIMIT);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" lowering ThreadLimit to %d.", MAX_THREAD_LIMIT);
thread_limit = MAX_THREAD_LIMIT;
}
else if (thread_limit < 1) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: Require ThreadLimit > 0, setting to 1");
thread_limit = 1;
}
apr_filepath_set(ap_coredump_dir, pconf);
apr_signal(sig, SIG_DFL);
if (ap_my_pid == parent_pid) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE,
0, ap_server_conf,
"seg fault or similar nasty error detected "
"in the parent process");
apr_os_sock_get(&csd, sock);
if (csd >= FD_SETSIZE) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_WARNING, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_WARNING, 0, NULL,
"new file descriptor %d is too large; you probably need "
"to rebuild Apache with a larger FD_SETSIZE "
"(currently %d)",
idle_worker_stack = worker_stack_create(pchild, ap_threads_per_child);
if (idle_worker_stack == NULL) {
- ap_log_error(APLOG_MARK, APLOG_ALERT|APLOG_NOERRNO, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_ALERT, 0, ap_server_conf,
"worker_stack_create() failed");
clean_child_exit(APEXIT_CHILDFATAL);
}
int status = bindprocessor(BINDPROCESS, (int)getpid(),
PROCESSOR_CLASS_ANY);
if (status != OK)
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_WARNING, errno,
+ ap_log_error(APLOG_MARK, APLOG_WARNING, errno,
ap_server_conf,
"processor unbind failed %d", status);
#endif
static int reported = 0;
if (!reported) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0,
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0,
ap_server_conf,
"server reached MaxClients setting, consider"
" raising the MaxClients setting");
free_length = idle_spawn_rate;
}
if (idle_spawn_rate >= 8) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, 0,
+ ap_log_error(APLOG_MARK, APLOG_INFO, 0,
ap_server_conf,
"server seems busy, (you may need "
"to increase StartServers, ThreadsPerChild "
/* Great, we've probably just lost a slot in the
* scoreboard. Somehow we don't know about this child.
*/
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_WARNING, 0,
+ ap_log_error(APLOG_MARK, APLOG_WARNING, 0,
ap_server_conf,
"long lost child came home! (pid %ld)",
(long)pid.pid);
first_server_limit = server_limit;
first_thread_limit = thread_limit;
if (changed_limit_at_restart) {
- ap_log_error(APLOG_MARK, APLOG_WARNING | APLOG_NOERRNO, 0, s,
+ ap_log_error(APLOG_MARK, APLOG_WARNING, 0, s,
"WARNING: Attempt to change ServerLimit or ThreadLimit "
"ignored during restart");
changed_limit_at_restart = 0;
hold_off_on_exponential_spawning = 10;
}
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, ap_server_conf,
"%s configured -- resuming normal operations",
ap_get_server_version());
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_INFO, 0, ap_server_conf,
"Server built: %s", ap_get_server_built());
#ifdef AP_MPM_WANT_SET_ACCEPT_LOCK_MECH
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_DEBUG, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, ap_server_conf,
"AcceptMutex: %s", ap_valid_accept_mutex_string);
#endif
restart_pending = shutdown_pending = 0;
const char *pidfile = NULL;
pidfile = ap_server_root_relative (pconf, ap_pid_fname);
if ( pidfile != NULL && unlink(pidfile) == 0)
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, 0,
+ ap_log_error(APLOG_MARK, APLOG_INFO, 0,
ap_server_conf,
"removed PID file %s (pid=%ld)",
pidfile, (long)getpid());
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0,
ap_server_conf, "caught SIGTERM, shutting down");
}
return 1;
ap_scoreboard_image->global->running_generation = ap_my_generation;
if (is_graceful) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, ap_server_conf,
AP_SIG_GRACEFUL_STRING " received. Doing graceful restart");
/* wake up the children...time to die. But we'll have more soon */
ap_mpm_pod_killpg(pod, ap_daemons_limit, TRUE);
ap_mpm_pod_killpg(pod, ap_daemons_limit, FALSE);
ap_reclaim_child_processes(1); /* Start with SIGTERM */
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, ap_server_conf,
"SIGHUP received. Attempting to restart");
}
ap_server_conf = s;
if ((num_listensocks = ap_setup_listeners(ap_server_conf)) < 1) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ALERT|APLOG_STARTUP, 0,
+ ap_log_error(APLOG_MARK, APLOG_ALERT|APLOG_STARTUP, 0,
NULL, "no listening sockets available, shutting down");
return DONE;
}
min_spare_threads = atoi(arg);
if (min_spare_threads <= 0) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: detected MinSpareThreads set to non-positive.");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Resetting to 1 to avoid almost certain Apache failure.");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Please read the documentation.");
min_spare_threads = 1;
}
* sure that it gets set before MaxClients in the pre_config stage. */
max_clients = atoi(arg);
if (max_clients < ap_threads_per_child) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: MaxClients (%d) must be at least as large",
max_clients);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" large as ThreadsPerChild (%d). Automatically",
ap_threads_per_child);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" increasing MaxClients to %d.",
ap_threads_per_child);
max_clients = ap_threads_per_child;
}
ap_daemons_limit = max_clients / ap_threads_per_child;
if ((max_clients > 0) && (max_clients % ap_threads_per_child)) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: MaxClients (%d) is not an integer multiple",
max_clients);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" of ThreadsPerChild (%d), lowering MaxClients to %d",
ap_threads_per_child,
ap_daemons_limit * ap_threads_per_child);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" for a maximum of %d child processes,",
ap_daemons_limit);
max_clients = ap_daemons_limit * ap_threads_per_child;
}
if (ap_daemons_limit > server_limit) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: MaxClients of %d would require %d servers,",
max_clients, ap_daemons_limit);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" and would exceed the ServerLimit value of %d.",
server_limit);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" Automatically lowering MaxClients to %d. To increase,",
server_limit);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" please see the ServerLimit directive.");
ap_daemons_limit = server_limit;
}
else if (ap_daemons_limit < 1) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: Require MaxClients > 0, setting to 1");
ap_daemons_limit = 1;
}
ap_threads_per_child = atoi(arg);
if (ap_threads_per_child > thread_limit) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: ThreadsPerChild of %d exceeds ThreadLimit "
"value of %d", ap_threads_per_child,
thread_limit);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"threads, lowering ThreadsPerChild to %d. To increase, please"
" see the", thread_limit);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" ThreadLimit directive.");
ap_threads_per_child = thread_limit;
}
else if (ap_threads_per_child < 1) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: Require ThreadsPerChild > 0, setting to 1");
ap_threads_per_child = 1;
}
server_limit = tmp_server_limit;
if (server_limit > MAX_SERVER_LIMIT) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: ServerLimit of %d exceeds compile time limit "
"of %d servers,", server_limit, MAX_SERVER_LIMIT);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" lowering ServerLimit to %d.", MAX_SERVER_LIMIT);
server_limit = MAX_SERVER_LIMIT;
}
else if (server_limit < 1) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: Require ServerLimit > 0, setting to 1");
server_limit = 1;
}
thread_limit = tmp_thread_limit;
if (thread_limit > MAX_THREAD_LIMIT) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: ThreadLimit of %d exceeds compile time limit "
"of %d servers,", thread_limit, MAX_THREAD_LIMIT);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" lowering ThreadLimit to %d.", MAX_THREAD_LIMIT);
thread_limit = MAX_THREAD_LIMIT;
}
else if (thread_limit < 1) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: Require ThreadLimit > 0, setting to 1");
thread_limit = 1;
}
is_parent_process = TRUE;
if (ap_setup_listeners(ap_server_conf) < 1) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ALERT, 0, s,
+ ap_log_error(APLOG_MARK, APLOG_ALERT, 0, s,
"no listening sockets available, shutting down");
return 1;
}
const char *pidfile = ap_server_root_relative(pconf, ap_pid_fname);
if (pidfile != NULL && remove(pidfile) == 0) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, APR_SUCCESS,
+ ap_log_error(APLOG_MARK, APLOG_INFO, APR_SUCCESS,
ap_server_conf, "removed PID file %s (pid=%d)",
pidfile, getpid());
}
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, ap_server_conf,
"caught SIGTERM, shutting down");
return 1;
}
set_signals();
if (ap_setup_listeners(ap_server_conf) < 1) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ALERT, 0, s,
+ ap_log_error(APLOG_MARK, APLOG_ALERT, 0, s,
"no listening sockets available, shutting down");
return FALSE;
}
}
ap_scoreboard_image->global->restart_time = apr_time_now();
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, ap_server_conf,
"%s configured -- resuming normal operations",
ap_get_server_version());
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_INFO, 0, ap_server_conf,
"Server built: %s", ap_get_server_built());
#ifdef AP_MPM_WANT_SET_ACCEPT_LOCK_MECH
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_DEBUG, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, ap_server_conf,
"AcceptMutex: %s", ap_valid_accept_mutex_string);
#endif
if (one_process) {
ap_min_spare_threads = atoi(arg);
if (ap_min_spare_threads <= 0) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: detected MinSpareThreads set to non-positive.");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Resetting to 1 to avoid almost certain Apache failure.");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Please read the documentation.");
ap_min_spare_threads = 1;
}
for (child_slot = 0; ap_scoreboard_image->parent[child_slot].pid != my_pid && child_slot < HARD_SERVER_LIMIT; child_slot++);
if (child_slot == HARD_SERVER_LIMIT) {
- ap_log_error(APLOG_MARK, APLOG_ERR|APLOG_NOERRNO, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0, ap_server_conf,
"child pid not found in scoreboard, exiting");
clean_child_exit(APEXIT_CHILDFATAL);
}
if (pReportRec->ExceptionNum == XCPT_ACCESS_VIOLATION ||
pReportRec->ExceptionNum == XCPT_INTEGER_DIVIDE_BY_ZERO) {
- ap_log_error(APLOG_MARK, APLOG_ERR|APLOG_NOERRNO, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0, ap_server_conf,
"caught exception in worker thread, initiating child shutdown pid=%d", getpid());
for (c=0; c<HARD_THREAD_LIMIT; c++) {
if (ap_scoreboard_image->servers[child_slot][c].tid == _gettid()) {
static int reported = 0;
if (!reported) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0, ap_server_conf,
"server reached MaxClients setting, consider"
" raising the MaxClients setting");
reported = 1;
}
else {
if (idle_spawn_rate >= 8) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_INFO, 0, ap_server_conf,
"server seems busy, (you may need "
"to increase StartServers, or Min/MaxSpareServers), "
"spawning %d children, there are %d idle, and "
int sockdes;
if (ap_setup_listeners(s) < 1 ) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ALERT, 0, s,
+ ap_log_error(APLOG_MARK, APLOG_ALERT, 0, s,
"no listening sockets available, shutting down");
return -1;
}
ap_server_conf = s;
if (setup_listeners(s)) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ALERT, status, s,
+ ap_log_error(APLOG_MARK, APLOG_ALERT, status, s,
"no listening sockets available, shutting down");
return -1;
}
startup_workers(ap_threads_to_start);
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, ap_server_conf,
"%s configured -- resuming normal operations",
ap_get_server_version());
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_INFO, 0, ap_server_conf,
"Server built: %s", ap_get_server_built());
#ifdef AP_MPM_WANT_SET_ACCEPT_LOCK_MECH
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_DEBUG, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, ap_server_conf,
"AcceptMutex: %s", ap_valid_accept_mutex_string);
#endif
show_server_data();
shutdown_listeners();*/
if (shutdown_pending) { /* Got an unload from the console */
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, ap_server_conf,
"caught SIGTERM, shutting down");
DBPRINT0 ("Shutdown pending. Waiting for threads to terminate...\n");
++ap_my_generation;
ap_scoreboard_image->global->running_generation = ap_my_generation;
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, ap_server_conf,
"Graceful restart requested, doing restart");
/* Wait for all of the threads to terminate before initiating the restart */
ap_threads_min_free = atoi(arg);
if (ap_threads_min_free <= 0) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: detected MinSpareServers set to non-positive.");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Resetting to 1 to avoid almost certain Apache failure.");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Please read the documentation.");
ap_threads_min_free = 1;
}
ap_threads_limit = atoi(arg);
if (ap_threads_limit > HARD_THREAD_LIMIT) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: MaxThreads of %d exceeds compile time limit "
"of %d threads,", ap_threads_limit, HARD_THREAD_LIMIT);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" lowering MaxThreads to %d. To increase, please "
"see the", HARD_THREAD_LIMIT);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" HARD_THREAD_LIMIT define in %s.",
AP_MPM_HARD_LIMITS_FILE);
ap_threads_limit = HARD_THREAD_LIMIT;
}
else if (ap_threads_limit < 1) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: Require MaxThreads > 0, setting to 1");
ap_threads_limit = 1;
}
chdir(ap_coredump_dir);
apr_signal(sig, SIG_DFL);
if (ap_my_pid == parent_pid) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE,
0, ap_server_conf,
"seg fault or similar nasty error detected "
"in the parent process");
int status = bindprocessor(BINDPROCESS, (int)getpid(),
PROCESSOR_CLASS_ANY);
if (status != OK) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_WARNING, errno,
+ ap_log_error(APLOG_MARK, APLOG_WARNING, errno,
ap_server_conf, "processor unbind failed %d", status);
}
#endif
static int reported = 0;
if (!reported) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0, ap_server_conf,
"server reached MaxClients setting, consider"
" raising the MaxClients setting");
reported = 1;
}
else {
if (idle_spawn_rate >= 8) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_INFO, 0, ap_server_conf,
"server seems busy, (you may need "
"to increase StartServers, or Min/MaxSpareServers), "
"spawning %d children, there are %d idle, and "
if (make_child(ap_server_conf, free_slots[i]) == -1) {
if(free_length == 1) {
shutdown_pending = 1;
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_EMERG, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_EMERG, 0, ap_server_conf,
"No active child processes: shutting down");
}
}
first_server_limit = server_limit;
if (changed_limit_at_restart) {
- ap_log_error(APLOG_MARK, APLOG_WARNING | APLOG_NOERRNO, 0, s,
+ ap_log_error(APLOG_MARK, APLOG_WARNING, 0, s,
"WARNING: Attempt to change ServerLimit "
"ignored during restart");
changed_limit_at_restart = 0;
hold_off_on_exponential_spawning = 10;
}
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, ap_server_conf,
"%s configured -- resuming normal operations",
ap_get_server_version());
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_INFO, 0, ap_server_conf,
"Server built: %s", ap_get_server_built());
#ifdef AP_MPM_WANT_SET_ACCEPT_LOCK_MECH
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_DEBUG, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, ap_server_conf,
"AcceptMutex: %s", ap_valid_accept_mutex_string);
#endif
restart_pending = shutdown_pending = 0;
* scoreboard. Somehow we don't know about this
* child.
*/
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_WARNING,
+ ap_log_error(APLOG_MARK, APLOG_WARNING,
0, ap_server_conf,
"long lost child came home! (pid %ld)", (long)pid.pid);
}
const char *pidfile = NULL;
pidfile = ap_server_root_relative (pconf, ap_pid_fname);
if ( pidfile != NULL && unlink(pidfile) == 0)
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO,
+ ap_log_error(APLOG_MARK, APLOG_INFO,
0, ap_server_conf,
"removed PID file %s (pid=%ld)",
pidfile, (long)getpid());
}
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, ap_server_conf,
"caught SIGTERM, shutting down");
return 1;
}
ap_scoreboard_image->global->running_generation = ap_my_generation;
if (is_graceful) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, ap_server_conf,
"Graceful restart requested, doing restart");
/* kill off the idle ones */
ap_log_error(APLOG_MARK, APLOG_WARNING, errno, ap_server_conf, "killpg SIGHUP");
}
ap_reclaim_child_processes(0); /* Not when just starting up */
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, ap_server_conf,
"SIGHUP received. Attempting to restart");
}
ap_server_conf = s;
if ((num_listensocks = ap_setup_listeners(ap_server_conf)) < 1) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ALERT|APLOG_STARTUP, 0,
+ ap_log_error(APLOG_MARK, APLOG_ALERT|APLOG_STARTUP, 0,
NULL, "no listening sockets available, shutting down");
return DONE;
}
ap_daemons_min_free = atoi(arg);
if (ap_daemons_min_free <= 0) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: detected MinSpareServers set to non-positive.");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Resetting to 1 to avoid almost certain Apache failure.");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Please read the documentation.");
ap_daemons_min_free = 1;
}
ap_daemons_limit = atoi(arg);
if (ap_daemons_limit > server_limit) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: MaxClients of %d exceeds ServerLimit value "
"of %d servers,", ap_daemons_limit, server_limit);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" lowering MaxClients to %d. To increase, please "
"see the ServerLimit", server_limit);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" directive.");
ap_daemons_limit = server_limit;
}
else if (ap_daemons_limit < 1) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: Require MaxClients > 0, setting to 1");
ap_daemons_limit = 1;
}
server_limit = tmp_server_limit;
if (server_limit > MAX_SERVER_LIMIT) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: ServerLimit of %d exceeds compile time limit "
"of %d servers,", server_limit, MAX_SERVER_LIMIT);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" lowering ServerLimit to %d.", MAX_SERVER_LIMIT);
server_limit = MAX_SERVER_LIMIT;
}
else if (server_limit < 1) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: Require ServerLimit > 0, setting to 1");
server_limit = 1;
}
ap_threads_per_child = atoi(arg);
if (ap_threads_per_child > HARD_THREAD_LIMIT) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: ThreadsPerChild of %d exceeds compile time"
" limit of %d threads,", ap_threads_per_child,
HARD_THREAD_LIMIT);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" lowering ThreadsPerChild to %d. To increase, please"
" see the HARD_THREAD_LIMIT define in %s.",
HARD_THREAD_LIMIT, AP_MPM_HARD_LIMITS_FILE);
ap_threads_per_child = HARD_THREAD_LIMIT;
}
else if (ap_threads_per_child < 1) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: Require ThreadsPerChild > 0, setting to 1");
ap_threads_per_child = 1;
}
if (num_completion_contexts >= ap_threads_per_child) {
static int reported = 0;
if (!reported) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_WARNING, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_WARNING, 0, ap_server_conf,
"Server ran out of threads to serve requests. Consider "
"raising the ThreadsPerChild setting");
reported = 1;
}
if (my_pid == parent_pid) {
- ap_log_error(APLOG_MARK, APLOG_DEBUG | APLOG_NOERRNO, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, ap_server_conf,
"Parent: Marked listeners as not inheritable.");
} else {
- ap_log_error(APLOG_MARK, APLOG_DEBUG | APLOG_NOERRNO, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, ap_server_conf,
"Child %d: Marked listeners as not inheritable.", my_pid);
}
return 1;
*/
ap_init_scoreboard(sb_shared);
- ap_log_error(APLOG_MARK, APLOG_DEBUG | APLOG_NOERRNO, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, ap_server_conf,
"Child %d: Retrieved our scoreboard from the parent.", my_pid);
}
apr_os_sock_put(&lr->sd, &nsd, s->process->pool);
}
- ap_log_error(APLOG_MARK, APLOG_DEBUG | APLOG_NOERRNO, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, ap_server_conf,
"Child %d: retrieved %d listeners from parent", my_pid, lcnt);
if (!set_listeners_noninheritable(s->process->pool)) {
new_job = (joblist *) malloc(sizeof(joblist));
if (new_job == NULL) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Ouch! Out of memory in add_job()!");
return;
}
*/
rv = apr_proc_mutex_unlock(start_mutex);
if (rv == APR_SUCCESS) {
- ap_log_error(APLOG_MARK,APLOG_NOTICE | APLOG_NOERRNO, rv, ap_server_conf,
+ ap_log_error(APLOG_MARK,APLOG_NOTICE, rv, ap_server_conf,
"Child %d: Released the start mutex", my_pid);
}
else {
return -1;
}
- ap_log_error(APLOG_MARK, APLOG_DEBUG | APLOG_NOERRNO, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, ap_server_conf,
"Parent: Sent the scoreboard to the child");
return 0;
}
}
}
- ap_log_error(APLOG_MARK, APLOG_DEBUG | APLOG_NOERRNO, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, ap_server_conf,
"Parent: Sent %d listeners to child %d", lcnt, dwProcessId);
return 0;
}
return -1;
}
else if (hShareError == INVALID_HANDLE_VALUE) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_CRIT, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_CRIT, 0, ap_server_conf,
"Parent: Failed to share error log with child.\n");
CloseHandle(hPipeWrite);
CloseHandle(hPipeRead);
else if (cld == SHUTDOWN_HANDLE) {
/* shutdown_event signalled */
shutdown_pending = 1;
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, APR_SUCCESS, s,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, APR_SUCCESS, s,
"Parent: Received shutdown signal -- Shutting down the server.");
if (ResetEvent(shutdown_event) == 0) {
ap_log_error(APLOG_MARK, APLOG_ERR, apr_get_os_error(), s,
* then signal the child process to exit.
*/
restart_pending = 1;
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, s,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, s,
"Parent: Received restart signal -- Restarting the server.");
if (ResetEvent(restart_event) == 0) {
ap_log_error(APLOG_MARK, APLOG_ERR, apr_get_os_error(), s,
if ( exitcode == APEXIT_CHILDFATAL
|| exitcode == APEXIT_CHILDINIT
|| exitcode == APEXIT_INIT) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0, ap_server_conf,
"Parent: child process exited with status %u -- Aborting.", exitcode);
}
else {
int i;
restart_pending = 1;
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, APR_SUCCESS, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, APR_SUCCESS, ap_server_conf,
"Parent: child process exited with status %u -- Restarting.", exitcode);
for (i = 0; i < ap_threads_per_child; i++) {
ap_update_child_status_from_indexes(0, i, SERVER_DEAD, NULL);
if (event_handles[CHILD_HANDLE]) {
rv = WaitForSingleObject(event_handles[CHILD_HANDLE], timeout);
if (rv == WAIT_OBJECT_0) {
- ap_log_error(APLOG_MARK,APLOG_NOTICE|APLOG_NOERRNO, APR_SUCCESS, ap_server_conf,
+ ap_log_error(APLOG_MARK,APLOG_NOTICE, APR_SUCCESS, ap_server_conf,
"Parent: Child process exited successfully.");
CloseHandle(event_handles[CHILD_HANDLE]);
event_handles[CHILD_HANDLE] = NULL;
}
else {
- ap_log_error(APLOG_MARK,APLOG_NOTICE|APLOG_NOERRNO, APR_SUCCESS, ap_server_conf,
+ ap_log_error(APLOG_MARK,APLOG_NOTICE, APR_SUCCESS, ap_server_conf,
"Parent: Forcing termination of child process %d ", event_handles[CHILD_HANDLE]);
TerminateProcess(event_handles[CHILD_HANDLE], 1);
CloseHandle(event_handles[CHILD_HANDLE]);
rv = mpm_merge_service_args(process->pool, mpm_new_argv,
fixed_args);
if (rv == APR_SUCCESS) {
- ap_log_error(APLOG_MARK,APLOG_NOERRNO|APLOG_INFO, 0, NULL,
+ ap_log_error(APLOG_MARK,APLOG_INFO, 0, NULL,
"Using ConfigArgs of the installed service "
"\"%s\".", service_name);
}
}
if (ap_setup_listeners(s) < 1) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ALERT|APLOG_STARTUP, 0,
+ ap_log_error(APLOG_MARK, APLOG_ALERT|APLOG_STARTUP, 0,
NULL, "no listening sockets available, shutting down");
return DONE;
}
const char *pidfile = ap_server_root_relative (pconf, ap_pid_fname);
if (pidfile != NULL && unlink(pidfile) == 0) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, APR_SUCCESS,
+ ap_log_error(APLOG_MARK, APLOG_INFO, APR_SUCCESS,
ap_server_conf, "removed PID file %s (pid=%ld)",
pidfile, GetCurrentProcessId());
}
(DWORD) strlen(value) + 1); /* for size of "value" */
if (rv == ERROR_SUCCESS) {
- ap_log_error(APLOG_MARK,APLOG_INFO|APLOG_NOERRNO,rv,NULL,
+ ap_log_error(APLOG_MARK,APLOG_INFO,rv,NULL,
"Registry stored HKLM\\" REGKEY "\\%s value %s", key, value);
}
(DWORD) bufsize); /* for size of "value" */
if (rv == ERROR_SUCCESS) {
- ap_log_error(APLOG_MARK,APLOG_INFO|APLOG_NOERRNO,rv,NULL,
+ ap_log_error(APLOG_MARK,APLOG_INFO,rv,NULL,
"Registry stored HKLM\\" REGKEY "\\%s", key);
}
rv = ap_registry_get_array(p, conf_key, "ConfigArgs", &svc_args);
if (rv != APR_SUCCESS) {
if (rv == ERROR_FILE_NOT_FOUND) {
- ap_log_error(APLOG_MARK, APLOG_INFO|APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_INFO, 0, NULL,
"No ConfigArgs registered for %s, perhaps "
"this service is not installed?",
mpm_service_name);
apr_filepath_set(ap_coredump_dir, pconf);
apr_signal(sig, SIG_DFL);
if (ap_my_pid == parent_pid) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE,
0, ap_server_conf,
"seg fault or similar nasty error detected "
"in the parent process");
apr_os_sock_get(&csd, sock);
if (csd >= FD_SETSIZE) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_WARNING, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_WARNING, 0, NULL,
"new file descriptor %d is too large; you probably need "
"to rebuild Apache with a larger FD_SETSIZE "
"(currently %d)",
int status = bindprocessor(BINDPROCESS, (int)getpid(),
PROCESSOR_CLASS_ANY);
if (status != OK)
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_WARNING, errno,
+ ap_log_error(APLOG_MARK, APLOG_WARNING, errno,
ap_server_conf,
"processor unbind failed %d", status);
#endif
static int reported = 0;
if (!reported) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0,
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0,
ap_server_conf,
"server reached MaxClients setting, consider"
" raising the MaxClients setting");
free_length = idle_spawn_rate;
}
if (idle_spawn_rate >= 8) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, 0,
+ ap_log_error(APLOG_MARK, APLOG_INFO, 0,
ap_server_conf,
"server seems busy, (you may need "
"to increase StartServers, ThreadsPerChild "
/* Great, we've probably just lost a slot in the
* scoreboard. Somehow we don't know about this child.
*/
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_WARNING, 0,
+ ap_log_error(APLOG_MARK, APLOG_WARNING, 0,
ap_server_conf,
"long lost child came home! (pid %ld)",
(long)pid.pid);
first_server_limit = server_limit;
first_thread_limit = thread_limit;
if (changed_limit_at_restart) {
- ap_log_error(APLOG_MARK, APLOG_WARNING | APLOG_NOERRNO, 0, s,
+ ap_log_error(APLOG_MARK, APLOG_WARNING, 0, s,
"WARNING: Attempt to change ServerLimit or ThreadLimit "
"ignored during restart");
changed_limit_at_restart = 0;
hold_off_on_exponential_spawning = 10;
}
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, ap_server_conf,
"%s configured -- resuming normal operations",
ap_get_server_version());
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_INFO, 0, ap_server_conf,
"Server built: %s", ap_get_server_built());
#ifdef AP_MPM_WANT_SET_ACCEPT_LOCK_MECH
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_DEBUG, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, ap_server_conf,
"AcceptMutex: %s", ap_valid_accept_mutex_string);
#endif
restart_pending = shutdown_pending = 0;
const char *pidfile = NULL;
pidfile = ap_server_root_relative (pconf, ap_pid_fname);
if ( pidfile != NULL && unlink(pidfile) == 0)
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, 0,
+ ap_log_error(APLOG_MARK, APLOG_INFO, 0,
ap_server_conf,
"removed PID file %s (pid=%ld)",
pidfile, (long)getpid());
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0,
ap_server_conf, "caught SIGTERM, shutting down");
}
return 1;
ap_scoreboard_image->global->running_generation = ap_my_generation;
if (is_graceful) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, ap_server_conf,
AP_SIG_GRACEFUL_STRING " received. Doing graceful restart");
/* wake up the children...time to die. But we'll have more soon */
ap_mpm_pod_killpg(pod, ap_daemons_limit, TRUE);
ap_mpm_pod_killpg(pod, ap_daemons_limit, FALSE);
ap_reclaim_child_processes(1); /* Start with SIGTERM */
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, 0, ap_server_conf,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, ap_server_conf,
"SIGHUP received. Attempting to restart");
}
ap_server_conf = s;
if ((num_listensocks = ap_setup_listeners(ap_server_conf)) < 1) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ALERT|APLOG_STARTUP, 0,
+ ap_log_error(APLOG_MARK, APLOG_ALERT|APLOG_STARTUP, 0,
NULL, "no listening sockets available, shutting down");
return DONE;
}
min_spare_threads = atoi(arg);
if (min_spare_threads <= 0) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: detected MinSpareThreads set to non-positive.");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Resetting to 1 to avoid almost certain Apache failure.");
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"Please read the documentation.");
min_spare_threads = 1;
}
* sure that it gets set before MaxClients in the pre_config stage. */
max_clients = atoi(arg);
if (max_clients < ap_threads_per_child) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: MaxClients (%d) must be at least as large",
max_clients);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" large as ThreadsPerChild (%d). Automatically",
ap_threads_per_child);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" increasing MaxClients to %d.",
ap_threads_per_child);
max_clients = ap_threads_per_child;
}
ap_daemons_limit = max_clients / ap_threads_per_child;
if ((max_clients > 0) && (max_clients % ap_threads_per_child)) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: MaxClients (%d) is not an integer multiple",
max_clients);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" of ThreadsPerChild (%d), lowering MaxClients to %d",
ap_threads_per_child,
ap_daemons_limit * ap_threads_per_child);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" for a maximum of %d child processes,",
ap_daemons_limit);
max_clients = ap_daemons_limit * ap_threads_per_child;
}
if (ap_daemons_limit > server_limit) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: MaxClients of %d would require %d servers,",
max_clients, ap_daemons_limit);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" and would exceed the ServerLimit value of %d.",
server_limit);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" Automatically lowering MaxClients to %d. To increase,",
server_limit);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" please see the ServerLimit directive.");
ap_daemons_limit = server_limit;
}
else if (ap_daemons_limit < 1) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: Require MaxClients > 0, setting to 1");
ap_daemons_limit = 1;
}
ap_threads_per_child = atoi(arg);
if (ap_threads_per_child > thread_limit) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: ThreadsPerChild of %d exceeds ThreadLimit "
"value of %d", ap_threads_per_child,
thread_limit);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"threads, lowering ThreadsPerChild to %d. To increase, please"
" see the", thread_limit);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" ThreadLimit directive.");
ap_threads_per_child = thread_limit;
}
else if (ap_threads_per_child < 1) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: Require ThreadsPerChild > 0, setting to 1");
ap_threads_per_child = 1;
}
server_limit = tmp_server_limit;
if (server_limit > MAX_SERVER_LIMIT) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: ServerLimit of %d exceeds compile time limit "
"of %d servers,", server_limit, MAX_SERVER_LIMIT);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" lowering ServerLimit to %d.", MAX_SERVER_LIMIT);
server_limit = MAX_SERVER_LIMIT;
}
else if (server_limit < 1) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: Require ServerLimit > 0, setting to 1");
server_limit = 1;
}
thread_limit = tmp_thread_limit;
if (thread_limit > MAX_THREAD_LIMIT) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: ThreadLimit of %d exceeds compile time limit "
"of %d servers,", thread_limit, MAX_THREAD_LIMIT);
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
" lowering ThreadLimit to %d.", MAX_THREAD_LIMIT);
thread_limit = MAX_THREAD_LIMIT;
}
else if (thread_limit < 1) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"WARNING: Require ThreadLimit > 0, setting to 1");
thread_limit = 1;
}
case 6: /* 344ms */
case 7: /* 1.4sec */
/* ok, now it's being annoying */
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_WARNING,
+ ap_log_error(APLOG_MARK, APLOG_WARNING,
0, ap_server_conf,
"child process %ld still did not exit, "
"sending a SIGTERM",
case 8: /* 6 sec */
/* die child scum */
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR,
+ ap_log_error(APLOG_MARK, APLOG_ERR,
0, ap_server_conf,
"child process %ld still did not exit, "
"sending a SIGKILL",
* exited, we will likely fail to bind to the port
* after the restart.
*/
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR,
+ ap_log_error(APLOG_MARK, APLOG_ERR,
0, ap_server_conf,
"could not make child process %ld exit, "
"attempting to continue anyway",
}
if (status == APEXIT_CHILDFATAL) {
- ap_log_error(APLOG_MARK, APLOG_ALERT|APLOG_NOERRNO,
+ ap_log_error(APLOG_MARK, APLOG_ALERT,
0, ap_server_conf,
"Child %" APR_PID_T_FMT
" returned a Fatal error..." APR_EOL_STR
default:
if (APR_PROC_CHECK_CORE_DUMP(why)) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE,
0, ap_server_conf,
"child pid %ld exit signal %s (%d), "
"possible coredump in %s",
ap_coredump_dir);
}
else {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE,
+ ap_log_error(APLOG_MARK, APLOG_NOTICE,
0, ap_server_conf,
"child pid %ld exit signal %s (%d)",
(long)pid->pid, sigdesc, signum);
return (atoi(&name[1]));
if (!(ent = getpwnam(name))) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP|APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"%s: bad user name %s", ap_server_argv0, name);
exit(1);
}
return (atoi(&name[1]));
if (!(ent = getgrnam(name))) {
- ap_log_error(APLOG_MARK, APLOG_STARTUP|APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL,
"%s: bad group name %s", ap_server_argv0, name);
exit(1);
}
/* Get the request... */
if (!read_request_line(r)) {
if (r->status == HTTP_REQUEST_URI_TOO_LARGE) {
- ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r,
"request failed: URI too long");
ap_send_error_response(r, 0);
ap_run_log_transaction(r);
if (!r->assbackwards) {
ap_get_mime_headers(r);
if (r->status != HTTP_REQUEST_TIME_OUT) {
- ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r,
"request failed: error reading the headers");
ap_send_error_response(r, 0);
ap_run_log_transaction(r);
* headers! Have to dink things just to make sure the error message
* comes through...
*/
- ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r,
"client sent invalid HTTP/0.9 request: HEAD %s",
r->uri);
r->header_only = 0;
* a Host: header, and the server MUST respond with 400 if it doesn't.
*/
r->status = HTTP_BAD_REQUEST;
- ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r,
"client sent HTTP/1.1 request without hostname "
"(see RFC2616 section 14.23): %s", r->uri);
}
}
else {
r->status = HTTP_EXPECTATION_FAILED;
- ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_INFO, 0, r,
"client sent an unrecognized expectation value of "
"Expect: %s", expect);
ap_send_error_response(r, 0);
ap_note_digest_auth_failure(r);
}
else {
- ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR,
+ ap_log_rerror(APLOG_MARK, APLOG_ERR,
0, r, "need AuthType to note auth failure: %s", r->uri);
}
}
return DECLINED;
if (!ap_auth_name(r)) {
- ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR,
+ ap_log_rerror(APLOG_MARK, APLOG_ERR,
0, r, "need AuthName: %s", r->uri);
return HTTP_INTERNAL_SERVER_ERROR;
}
if (strcasecmp(ap_getword(r->pool, &auth_line, ' '), "Basic")) {
/* Client tried to authenticate using wrong auth scheme */
- ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r,
"client used wrong authentication scheme: %s", r->uri);
ap_note_basic_auth_failure(r);
return HTTP_UNAUTHORIZED;
static int decl_die(int status, char *phase, request_rec *r)
{
if (status == DECLINED) {
- ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_CRIT, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_CRIT, 0, r,
"configuration error: couldn't %s: %s", phase, r->uri);
return HTTP_INTERNAL_SERVER_ERROR;
}
return OK;
}
- ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r,
"object is not a file, directory or symlink: %s",
r->filename);
return HTTP_FORBIDDEN;
* handler. Leave INFO notes here for module debugging.
*/
if (r->filename == NULL) {
- ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_INFO, 0, r,
"Module bug? Request filename is missing for URI %s",
r->uri);
return OK;
if ((rv = apr_filepath_merge(&entry_dir, NULL, r->filename,
APR_FILEPATH_NOTRELATIVE, r->pool))
!= APR_SUCCESS) {
- ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_INFO, 0, r,
"Module bug? Request filename path %s is invalid or "
"or not absolute for uri %s",
r->filename, r->uri);
*/
if ((res = resolve_symlink(r->filename, &thisinfo,
opts, r->pool)) != OK) {
- ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r,
"Symbolic link not allowed: %s",
r->filename);
return r->status = res;
break;
}
else if (thisinfo.filetype != APR_DIR) {
- ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r,
"symlink doesn't point to a file or "
"directory: %s",
r->filename);
x if (r->finfo.filetype != APR_DIR
x && (res = resolve_symlink(r->filename, r->info, ap_allow_options(r),
x r->pool))) {
- x ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0, r,
+ x ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r,
x "Symbolic link not allowed: %s", r->filename);
x return res;
x }
return APR_SUCCESS;
}
if (apr_shm_size_get(ap_scoreboard_shm) < scoreboard_size) {
- ap_log_error(APLOG_MARK, APLOG_CRIT | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_CRIT, 0, NULL,
"Fatal error: shared scoreboard too small for child!");
apr_shm_detach(ap_scoreboard_shm);
ap_scoreboard_shm = NULL;
/* A simple malloc will suffice */
void *sb_mem = calloc(1, scoreboard_size);
if (sb_mem == NULL) {
- ap_log_error(APLOG_MARK, APLOG_CRIT | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_CRIT, 0, NULL,
"(%d)%s: cannot allocate scoreboard",
errno, strerror(errno));
return HTTP_INTERNAL_SERVER_ERROR;
AP_DECLARE(int) ap_cfg_closefile(ap_configfile_t *cfp)
{
#ifdef DEBUG
- ap_log_error(APLOG_MARK, APLOG_DEBUG|APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, NULL,
"Done with config file %s", cfp->name);
#endif
return (cfp->close == NULL) ? 0 : cfp->close(cfp->param);
#endif
if (name == NULL) {
- ap_log_error(APLOG_MARK, APLOG_ERR | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0, NULL,
"Internal error: pcfg_openfile() called with NULL filename");
return APR_EBADF;
}
status = apr_file_open(&file, name, APR_READ | APR_BUFFERED, APR_OS_DEFAULT, p);
#ifdef DEBUG
- ap_log_error(APLOG_MARK, APLOG_DEBUG | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, NULL,
"Opening config file %s (%s)",
name, (status != APR_SUCCESS) ?
apr_strerror(status, buf, sizeof(buf)) : "successful");
#else
strcmp(name, "/dev/null") != 0) {
#endif /* WIN32 || OS2 */
- ap_log_error(APLOG_MARK, APLOG_ERR | APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0, NULL,
"Access to file %s denied by server: not a regular file",
name);
apr_file_close(file);
{
ap_configfile_t *new_cfg = apr_palloc(p, sizeof(*new_cfg));
#ifdef DEBUG
- ap_log_error(APLOG_MARK, APLOG_DEBUG | APLOG_NOERRNO, 0, NULL, "Opening config handler %s", descr);
+ ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, NULL, "Opening config handler %s", descr);
#endif
new_cfg->param = param;
new_cfg->name = descr;
;
#ifdef DEBUG_CFG_LINES
- ap_log_error(APLOG_MARK, APLOG_DEBUG|APLOG_NOERRNO, 0, NULL, "Read config: %s", buf);
+ ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, NULL, "Read config: %s", buf);
#endif
return 0;
} else {
--i;
buf[i] = '\0';
#ifdef DEBUG_CFG_LINES
- ap_log_error(APLOG_MARK, APLOG_DEBUG|APLOG_NOERRNO, 0, NULL, "Read config: %s", buf);
+ ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, NULL, "Read config: %s", buf);
#endif
return 0;
}
if (!server_hostname)
server_hostname = apr_pstrdup(a, "127.0.0.1");
- ap_log_perror(APLOG_MARK, APLOG_ALERT|APLOG_NOERRNO|APLOG_STARTUP, 0, a,
+ ap_log_perror(APLOG_MARK, APLOG_ALERT|APLOG_STARTUP, 0, a,
"%s: Could not determine the server's fully qualified "
"domain name, using %s for ServerName",
ap_server_argv0, server_hostname);
outf = r_filters;
}
else {
- ap_log_error(APLOG_MARK, APLOG_ERR|APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0, NULL,
"a content filter was added without a request: %s", frec->name);
return NULL;
}
outf = p_filters;
}
else {
- ap_log_error(APLOG_MARK, APLOG_ERR|APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0, NULL,
"a protocol filter was added without a request: %s", frec->name);
return NULL;
}
}
}
- ap_log_error(APLOG_MARK, APLOG_ERR|APLOG_NOERRNO, 0, NULL,
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0, NULL,
"an unknown filter was not added: %s", name);
return NULL;
}
while (1) {
if ((*getsfunc) (w, MAX_STRING_LEN - 1, getsfunc_data) == 0) {
- ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR|APLOG_TOCLIENT, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_ERR|APLOG_TOCLIENT, 0, r,
"Premature end of script headers: %s",
apr_filename_of_pathname(r->filename));
return HTTP_INTERNAL_SERVER_ERROR;
++maybeASCII;
}
if (maybeASCII > maybeEBCDIC) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0, r->server,
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0, r->server,
"CGI Interface Error: Script headers apparently ASCII: (CGI = %s)",
r->filename);
inbytes_left = outbytes_left = cp - w;
}
}
- ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR|APLOG_TOCLIENT, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_ERR|APLOG_TOCLIENT, 0, r,
"%s: %s", malformed,
apr_filename_of_pathname(r->filename));
return HTTP_INTERNAL_SERVER_ERROR;
while ((len = ap_get_client_block(r, buffer, READ_BLOCKSIZE)) > 0) {
total_read += len;
if (limit_xml_body && total_read > limit_xml_body) {
- ap_log_rerror(APLOG_MARK, APLOG_ERR | APLOG_NOERRNO, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r,
"XML request body is larger than the configured "
"limit of %lu", (unsigned long)limit_xml_body);
goto read_error;
/* tell the parser that we're done */
status = apr_xml_parser_done(parser, pdoc);
if (status) {
- ap_log_rerror(APLOG_MARK, APLOG_ERR | APLOG_NOERRNO, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r,
"XML parser error (at end). status=%d", status);
return HTTP_BAD_REQUEST;
}
parser_error:
(void) apr_xml_parser_geterror(parser, errbuf, sizeof(errbuf));
- ap_log_rerror(APLOG_MARK, APLOG_ERR | APLOG_NOERRNO, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r,
"%s", errbuf);
/* FALLTHRU */
}
p += apr_snprintf(p, sizeof(buf) - (p - buf), " %ux%u",
total, count[IPHASH_TABLE_SIZE - 1]);
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_DEBUG, main_s, buf);
+ ap_log_error(APLOG_MARK, APLOG_DEBUG, main_s, buf);
}
#endif
ic->server = s;
if (sar->host_port != ic->sar->host_port) {
/* one of the two is a * port, the other isn't */
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0, main_s,
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0, main_s,
"VirtualHost %s:%u -- mixing * "
"ports and non-* ports with "
"a NameVirtualHost address is not supported,"
ipaddr_chain *ic = *pic;
if (ic->server == NULL) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_WARNING, 0, main_s,
+ ap_log_error(APLOG_MARK, APLOG_WARNING, 0, main_s,
"NameVirtualHost %s:%u has no VirtualHosts",
ic->sar->virthost, ic->sar->host_port);
*pic = ic->next;
ic = find_default_server(sar->host_port);
if (!ic || !add_name_vhost_config(p, main_s, s, sar, ic)) {
if (ic && ic->sar->host_port != 0) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_WARNING,
+ ap_log_error(APLOG_MARK, APLOG_WARNING,
0, main_s, "_default_ VirtualHost "
"overlap on port %u, the first has "
"precedence", sar->host_port);
*iphash_table_tail[bucket] = ic;
}
else if (!add_name_vhost_config(p, main_s, s, sar, ic)) {
- ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_WARNING,
+ ap_log_error(APLOG_MARK, APLOG_WARNING,
0, main_s, "VirtualHost %s:%u overlaps "
"with VirtualHost %s:%u, the first has "
"precedence, perhaps you need a "
bad:
r->status = HTTP_BAD_REQUEST;
- ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0, r,
+ ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r,
"Client sent malformed Host header");
return;
}