mirror of
https://github.com/apache/httpd.git
synced 2026-10-23 22:49:01 +03:00
Merge r1534995, r1560482, r1728779, r1805491, r1861528, r1868016, r1874470, r1874602, r1875769, r1875811 from trunk:
don't ignore some apr_procattr failures (clang scan-build) doxygen improvements Standardize order of "extern" and XXX_DECLARE_YYY. Fix some compilation warning when MIME_MAGIC_DEBUG is defined. warning: format ‘%x’ expects argument of type ‘unsigned int’, but argument <n> has type ‘<something> *’ [-Wformat=] style: cmd_rec at the bottom no functional change Fix a typo in a message. Reported and fixed by Christian Bartolomäus (bartolin gmx.de) PR 63806 malloc -> ap_malloc bz #63967 Slighly simplify code. No need to set to NULL or 0 fields that are apr_pcalloc'ed. Axe 'set_cookie_enable' and use 'ap_set_flag_slot' instead. (based on ideas taken from r1874389) Parentheses around AP_BUCKET_IS_EOR argument. Fix a typo Submitted by: trawick, rjung, jailletc36, covener, jailletc36, gbechis, jailletc36, ylavic, jailletc36 Reviewed by: jailletc36, gbechis, jim git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.4.x@1876885 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
25
STATUS
25
STATUS
@@ -135,31 +135,6 @@ RELEASE SHOWSTOPPERS:
|
||||
PATCHES ACCEPTED TO BACKPORT FROM TRUNK:
|
||||
[ start all new proposals below, under PATCHES PROPOSED. ]
|
||||
|
||||
*) Easy patches: synch 2.4.x and trunk
|
||||
- core/log: don't ignore some apr_procattr failures (clang scan-build)
|
||||
- doxygen improvements
|
||||
- core: Standardize order of "extern" and XXX_DECLARE_YYY
|
||||
- mod_mime_magic: Fix some compilation warning when MIME_MAGIC_DEBUG is defined.
|
||||
- mod_alias: style: cmd_rec at the bottom
|
||||
- core: Fix a typo in a message
|
||||
- mpm_winnt: malloc -> ap_malloc
|
||||
- mod_usertrack: Slighly simplify code
|
||||
- code: Parentheses around AP_BUCKET_IS_EOR argument
|
||||
- mod_dialup: Fix a typo
|
||||
trunk patch:
|
||||
- http://svn.apache.org/r1534995
|
||||
- http://svn.apache.org/r1560482
|
||||
- http://svn.apache.org/r1728779
|
||||
- http://svn.apache.org/r1805491
|
||||
- http://svn.apache.org/r1861528
|
||||
- http://svn.apache.org/r1868016
|
||||
- http://svn.apache.org/r1874470
|
||||
- http://svn.apache.org/r1874602
|
||||
- http://svn.apache.org/r1875769
|
||||
- http://svn.apache.org/r1875811
|
||||
2.4.x patch: svn merge -c 1534995,1560482,1728779,1805491,1861528,1868016,1874470,1874602,1875769,1875811 ^/httpd/httpd/trunk .
|
||||
+1: jailletc36, gbechis, jim
|
||||
|
||||
*) core: default_handler: cleanup outputed brigade before leaving.
|
||||
trunk patch:
|
||||
- http://svn.apache.org/r1783041
|
||||
|
||||
101
include/ap_mpm.h
101
include/ap_mpm.h
@@ -88,6 +88,7 @@ extern "C" {
|
||||
* @param plog the log pool, reset after the config file is read
|
||||
* @param server_conf the global server config.
|
||||
* @return DONE for shutdown OK otherwise.
|
||||
* @ingroup hooks
|
||||
*/
|
||||
AP_DECLARE_HOOK(int, mpm, (apr_pool_t *pconf, apr_pool_t *plog, server_rec *server_conf))
|
||||
|
||||
@@ -113,42 +114,75 @@ AP_DECLARE(apr_status_t) ap_os_create_privileged_process(
|
||||
apr_procattr_t *attr,
|
||||
apr_pool_t *p);
|
||||
|
||||
/* Subtypes/Values for AP_MPMQ_IS_THREADED and AP_MPMQ_IS_FORKED */
|
||||
#define AP_MPMQ_NOT_SUPPORTED 0 /* This value specifies that an */
|
||||
/* MPM is not capable of */
|
||||
/* threading or forking. */
|
||||
#define AP_MPMQ_STATIC 1 /* This value specifies that */
|
||||
/* an MPM is using a static */
|
||||
/* number of threads or daemons */
|
||||
#define AP_MPMQ_DYNAMIC 2 /* This value specifies that */
|
||||
/* an MPM is using a dynamic */
|
||||
/* number of threads or daemons */
|
||||
/** @defgroup mpmq MPM query
|
||||
* @{
|
||||
*/
|
||||
|
||||
/* Values returned for AP_MPMQ_MPM_STATE */
|
||||
/** @defgroup thrdfrk Subtypes/Values returned for AP_MPMQ_IS_THREADED and AP_MPMQ_IS_FORKED
|
||||
* @ingroup mpmq
|
||||
* @{
|
||||
*/
|
||||
#define AP_MPMQ_NOT_SUPPORTED 0 /**< This value specifies that an
|
||||
* MPM is not capable of
|
||||
* threading or forking. */
|
||||
#define AP_MPMQ_STATIC 1 /**< This value specifies that
|
||||
* an MPM is using a static
|
||||
* number of threads or daemons */
|
||||
#define AP_MPMQ_DYNAMIC 2 /**< This value specifies that
|
||||
* an MPM is using a dynamic
|
||||
* number of threads or daemons */
|
||||
/** @} */
|
||||
|
||||
/** @defgroup qstate Values returned for AP_MPMQ_MPM_STATE
|
||||
* @ingroup mpmq
|
||||
* @{
|
||||
*/
|
||||
#define AP_MPMQ_STARTING 0
|
||||
#define AP_MPMQ_RUNNING 1
|
||||
#define AP_MPMQ_STOPPING 2
|
||||
/** @} */
|
||||
|
||||
#define AP_MPMQ_MAX_DAEMON_USED 1 /* Max # of daemons used so far */
|
||||
#define AP_MPMQ_IS_THREADED 2 /* MPM can do threading */
|
||||
#define AP_MPMQ_IS_FORKED 3 /* MPM can do forking */
|
||||
#define AP_MPMQ_HARD_LIMIT_DAEMONS 4 /* The compiled max # daemons */
|
||||
#define AP_MPMQ_HARD_LIMIT_THREADS 5 /* The compiled max # threads */
|
||||
#define AP_MPMQ_MAX_THREADS 6 /* # of threads/child by config */
|
||||
#define AP_MPMQ_MIN_SPARE_DAEMONS 7 /* Min # of spare daemons */
|
||||
#define AP_MPMQ_MIN_SPARE_THREADS 8 /* Min # of spare threads */
|
||||
#define AP_MPMQ_MAX_SPARE_DAEMONS 9 /* Max # of spare daemons */
|
||||
#define AP_MPMQ_MAX_SPARE_THREADS 10 /* Max # of spare threads */
|
||||
#define AP_MPMQ_MAX_REQUESTS_DAEMON 11 /* Max # of requests per daemon */
|
||||
#define AP_MPMQ_MAX_DAEMONS 12 /* Max # of daemons by config */
|
||||
#define AP_MPMQ_MPM_STATE 13 /* starting, running, stopping */
|
||||
#define AP_MPMQ_IS_ASYNC 14 /* MPM can process async connections */
|
||||
#define AP_MPMQ_GENERATION 15 /* MPM generation */
|
||||
#define AP_MPMQ_HAS_SERF 16 /* MPM can drive serf internally */
|
||||
/** @defgroup qcodes Query codes for ap_mpm_query()
|
||||
* @ingroup mpmq
|
||||
* @{
|
||||
*/
|
||||
/** Max # of daemons used so far */
|
||||
#define AP_MPMQ_MAX_DAEMON_USED 1
|
||||
/** MPM can do threading */
|
||||
#define AP_MPMQ_IS_THREADED 2
|
||||
/** MPM can do forking */
|
||||
#define AP_MPMQ_IS_FORKED 3
|
||||
/** The compiled max # daemons */
|
||||
#define AP_MPMQ_HARD_LIMIT_DAEMONS 4
|
||||
/** The compiled max # threads */
|
||||
#define AP_MPMQ_HARD_LIMIT_THREADS 5
|
||||
/** \# of threads/child by config */
|
||||
#define AP_MPMQ_MAX_THREADS 6
|
||||
/** Min # of spare daemons */
|
||||
#define AP_MPMQ_MIN_SPARE_DAEMONS 7
|
||||
/** Min # of spare threads */
|
||||
#define AP_MPMQ_MIN_SPARE_THREADS 8
|
||||
/** Max # of spare daemons */
|
||||
#define AP_MPMQ_MAX_SPARE_DAEMONS 9
|
||||
/** Max # of spare threads */
|
||||
#define AP_MPMQ_MAX_SPARE_THREADS 10
|
||||
/** Max # of requests per daemon */
|
||||
#define AP_MPMQ_MAX_REQUESTS_DAEMON 11
|
||||
/** Max # of daemons by config */
|
||||
#define AP_MPMQ_MAX_DAEMONS 12
|
||||
/** starting, running, stopping */
|
||||
#define AP_MPMQ_MPM_STATE 13
|
||||
/** MPM can process async connections */
|
||||
#define AP_MPMQ_IS_ASYNC 14
|
||||
/** MPM generation */
|
||||
#define AP_MPMQ_GENERATION 15
|
||||
/** MPM can drive serf internally */
|
||||
#define AP_MPMQ_HAS_SERF 16
|
||||
/** @} */
|
||||
|
||||
/**
|
||||
* Query a property of the current MPM.
|
||||
* @param query_code One of APM_MPMQ_*
|
||||
* @param query_code One of AP_MPMQ_*
|
||||
* @param result A location to place the result of the query
|
||||
* @return APR_EGENERAL if an mpm-query hook has not been registered;
|
||||
* APR_SUCCESS or APR_ENOTIMPL otherwise
|
||||
@@ -159,6 +193,7 @@ AP_DECLARE(apr_status_t) ap_os_create_privileged_process(
|
||||
*/
|
||||
AP_DECLARE(apr_status_t) ap_mpm_query(int query_code, int *result);
|
||||
|
||||
/** @} */
|
||||
|
||||
typedef void (ap_mpm_callback_fn_t)(void *baton);
|
||||
|
||||
@@ -191,6 +226,7 @@ typedef enum mpm_child_status {
|
||||
* scoreboard slot.
|
||||
* @param state One of the mpm_child_status values. Modules should ignore
|
||||
* unrecognized values.
|
||||
* @ingroup hooks
|
||||
*/
|
||||
AP_DECLARE_HOOK(void,child_status,(server_rec *s, pid_t pid, ap_generation_t gen,
|
||||
int slot, mpm_child_status state))
|
||||
@@ -201,6 +237,7 @@ AP_DECLARE_HOOK(void,child_status,(server_rec *s, pid_t pid, ap_generation_t gen
|
||||
*
|
||||
* @param s The main server_rec.
|
||||
* @param gen The server generation which is now completely finished.
|
||||
* @ingroup hooks
|
||||
*/
|
||||
AP_DECLARE_HOOK(void,end_generation,(server_rec *s, ap_generation_t gen))
|
||||
|
||||
@@ -224,6 +261,14 @@ typedef struct ap_exception_info_t {
|
||||
pid_t pid;
|
||||
} ap_exception_info_t;
|
||||
|
||||
/**
|
||||
* Run the fatal_exception hook for each module; this hook is run
|
||||
* from some MPMs in the event of a child process crash, if the
|
||||
* server was built with --enable-exception-hook and the
|
||||
* EnableExceptionHook directive is On.
|
||||
* @param ei information about the exception
|
||||
* @ingroup hooks
|
||||
*/
|
||||
AP_DECLARE_HOOK(int,fatal_exception,(ap_exception_info_t *ei))
|
||||
#endif /*AP_ENABLE_EXCEPTION_HOOK*/
|
||||
|
||||
|
||||
@@ -186,6 +186,8 @@ AP_DECLARE(apr_size_t) ap_regerror(int errcode, const ap_regex_t *preg,
|
||||
* Return an array of named regex backreferences
|
||||
* @param preg The precompiled regex
|
||||
* @param names The array to which the names will be added
|
||||
* @param prefix An optional prefix to add to the returned names. AP_REG_MATCH
|
||||
* is the recommended prefix.
|
||||
* @param upper If non zero, uppercase the names
|
||||
*/
|
||||
AP_DECLARE(int) ap_regname(const ap_regex_t *preg,
|
||||
|
||||
@@ -1298,6 +1298,7 @@ AP_CORE_DECLARE(void *) ap_set_config_vectors(server_rec *server,
|
||||
* Run the header parser functions for each module
|
||||
* @param r The current request
|
||||
* @return OK or DECLINED
|
||||
* @ingroup hooks
|
||||
*/
|
||||
AP_DECLARE_HOOK(int,header_parser,(request_rec *r))
|
||||
|
||||
@@ -1307,6 +1308,7 @@ AP_DECLARE_HOOK(int,header_parser,(request_rec *r))
|
||||
* @param plog The logging streams pool
|
||||
* @param ptemp The temporary pool
|
||||
* @return OK or DECLINED on success anything else is a error
|
||||
* @ingroup hooks
|
||||
*/
|
||||
AP_DECLARE_HOOK(int,pre_config,(apr_pool_t *pconf,apr_pool_t *plog,
|
||||
apr_pool_t *ptemp))
|
||||
@@ -1318,6 +1320,7 @@ AP_DECLARE_HOOK(int,pre_config,(apr_pool_t *pconf,apr_pool_t *plog,
|
||||
* @param ptemp The temporary pool
|
||||
* @param s the server to operate upon
|
||||
* @return OK or DECLINED on success anything else is a error
|
||||
* @ingroup hooks
|
||||
*/
|
||||
AP_DECLARE_HOOK(int,check_config,(apr_pool_t *pconf, apr_pool_t *plog,
|
||||
apr_pool_t *ptemp, server_rec *s))
|
||||
@@ -1330,7 +1333,7 @@ AP_DECLARE_HOOK(int,check_config,(apr_pool_t *pconf, apr_pool_t *plog,
|
||||
* @note To avoid reordering problems due to different buffering, hook
|
||||
* functions should only apr_file_*() to print to stdout/stderr and
|
||||
* not simple printf()/fprintf().
|
||||
*
|
||||
* @ingroup hooks
|
||||
*/
|
||||
AP_DECLARE_HOOK(void,test_config,(apr_pool_t *pconf, server_rec *s))
|
||||
|
||||
@@ -1341,6 +1344,7 @@ AP_DECLARE_HOOK(void,test_config,(apr_pool_t *pconf, server_rec *s))
|
||||
* @param ptemp The temporary pool
|
||||
* @param s The list of server_recs
|
||||
* @return OK or DECLINED on success anything else is a error
|
||||
* @ingroup hooks
|
||||
*/
|
||||
AP_DECLARE_HOOK(int,post_config,(apr_pool_t *pconf,apr_pool_t *plog,
|
||||
apr_pool_t *ptemp,server_rec *s))
|
||||
@@ -1352,6 +1356,7 @@ AP_DECLARE_HOOK(int,post_config,(apr_pool_t *pconf,apr_pool_t *plog,
|
||||
* @param ptemp The temporary pool
|
||||
* @param s The list of server_recs
|
||||
* @return OK or DECLINED on success anything else is a error
|
||||
* @ingroup hooks
|
||||
*/
|
||||
AP_DECLARE_HOOK(int,open_logs,(apr_pool_t *pconf,apr_pool_t *plog,
|
||||
apr_pool_t *ptemp,server_rec *s))
|
||||
@@ -1360,6 +1365,7 @@ AP_DECLARE_HOOK(int,open_logs,(apr_pool_t *pconf,apr_pool_t *plog,
|
||||
* Run the child_init functions for each module
|
||||
* @param pchild The child pool
|
||||
* @param s The list of server_recs in this server
|
||||
* @ingroup hooks
|
||||
*/
|
||||
AP_DECLARE_HOOK(void,child_init,(apr_pool_t *pchild, server_rec *s))
|
||||
|
||||
@@ -1367,6 +1373,7 @@ AP_DECLARE_HOOK(void,child_init,(apr_pool_t *pchild, server_rec *s))
|
||||
* Run the handler functions for each module
|
||||
* @param r The request_rec
|
||||
* @remark non-wildcard handlers should HOOK_MIDDLE, wildcard HOOK_LAST
|
||||
* @ingroup hooks
|
||||
*/
|
||||
AP_DECLARE_HOOK(int,handler,(request_rec *r))
|
||||
|
||||
@@ -1380,6 +1387,7 @@ AP_DECLARE_HOOK(int,handler,(request_rec *r))
|
||||
* @param lookup_uri Controls whether the caller actually wants content or not.
|
||||
* lookup is set when the quick_handler is called out of
|
||||
* ap_sub_req_lookup_uri()
|
||||
* @ingroup hooks
|
||||
*/
|
||||
AP_DECLARE_HOOK(int,quick_handler,(request_rec *r, int lookup_uri))
|
||||
|
||||
@@ -1387,6 +1395,7 @@ AP_DECLARE_HOOK(int,quick_handler,(request_rec *r, int lookup_uri))
|
||||
* Retrieve the optional functions for each module.
|
||||
* This is run immediately before the server starts. Optional functions should
|
||||
* be registered during the hook registration phase.
|
||||
* @ingroup hooks
|
||||
*/
|
||||
AP_DECLARE_HOOK(void,optional_fn_retrieve,(void))
|
||||
|
||||
@@ -1403,6 +1412,7 @@ AP_DECLARE_HOOK(void,optional_fn_retrieve,(void))
|
||||
* APR_ENOENT or APR_ENOTDIR if no htaccess file exists,
|
||||
* AP_DECLINED to let later modules do the opening,
|
||||
* any other error code on error.
|
||||
* @ingroup hooks
|
||||
*/
|
||||
AP_DECLARE_HOOK(apr_status_t,open_htaccess,
|
||||
(request_rec *r, const char *dir_name, const char *access_name,
|
||||
|
||||
@@ -589,7 +589,7 @@ AP_DECLARE_DATA extern const apr_bucket_type_t ap_bucket_type_eor;
|
||||
* @param e The bucket to inspect
|
||||
* @return true or false
|
||||
*/
|
||||
#define AP_BUCKET_IS_EOR(e) (e->type == &ap_bucket_type_eor)
|
||||
#define AP_BUCKET_IS_EOR(e) ((e)->type == &ap_bucket_type_eor)
|
||||
|
||||
/**
|
||||
* Make the bucket passed in an End Of REQUEST (EOR) bucket
|
||||
|
||||
@@ -2347,7 +2347,7 @@ AP_DECLARE(void) ap_bin2hex(const void *src, apr_size_t srclen, char *dest);
|
||||
|
||||
/**
|
||||
* Short function to execute a command and return the first line of
|
||||
* output minus \r \n. Useful for "obscuring" passwords via exec calls
|
||||
* output minus \\r \\n. Useful for "obscuring" passwords via exec calls
|
||||
* @param p the pool to allocate from
|
||||
* @param cmd the command to execute
|
||||
* @param argv the arguments to pass to the cmd
|
||||
|
||||
@@ -373,33 +373,6 @@ static const char *add_redirect_regex(cmd_parms *cmd, void *dirconf,
|
||||
return add_redirect_internal(cmd, dirconf, arg1, arg2, arg3, 1);
|
||||
}
|
||||
|
||||
static const command_rec alias_cmds[] =
|
||||
{
|
||||
AP_INIT_TAKE12("Alias", add_alias, NULL, RSRC_CONF | ACCESS_CONF,
|
||||
"a fakename and a realname, or a realname in a Location"),
|
||||
AP_INIT_TAKE12("ScriptAlias", add_alias, "cgi-script", RSRC_CONF | ACCESS_CONF,
|
||||
"a fakename and a realname, or a realname in a Location"),
|
||||
AP_INIT_TAKE123("Redirect", add_redirect, (void *) HTTP_MOVED_TEMPORARILY,
|
||||
OR_FILEINFO,
|
||||
"an optional status, then document to be redirected and "
|
||||
"destination URL"),
|
||||
AP_INIT_TAKE2("AliasMatch", add_alias_regex, NULL, RSRC_CONF,
|
||||
"a regular expression and a filename"),
|
||||
AP_INIT_TAKE2("ScriptAliasMatch", add_alias_regex, "cgi-script", RSRC_CONF,
|
||||
"a regular expression and a filename"),
|
||||
AP_INIT_TAKE23("RedirectMatch", add_redirect_regex,
|
||||
(void *) HTTP_MOVED_TEMPORARILY, OR_FILEINFO,
|
||||
"an optional status, then a regular expression and "
|
||||
"destination URL"),
|
||||
AP_INIT_TAKE2("RedirectTemp", add_redirect2,
|
||||
(void *) HTTP_MOVED_TEMPORARILY, OR_FILEINFO,
|
||||
"a document to be redirected, then the destination URL"),
|
||||
AP_INIT_TAKE2("RedirectPermanent", add_redirect2,
|
||||
(void *) HTTP_MOVED_PERMANENTLY, OR_FILEINFO,
|
||||
"a document to be redirected, then the destination URL"),
|
||||
{NULL}
|
||||
};
|
||||
|
||||
static int alias_matches(const char *uri, const char *alias_fakename)
|
||||
{
|
||||
const char *aliasp = alias_fakename, *urip = uri;
|
||||
@@ -705,6 +678,34 @@ static int fixup_redir(request_rec *r)
|
||||
return DECLINED;
|
||||
}
|
||||
|
||||
static const command_rec alias_cmds[] =
|
||||
{
|
||||
AP_INIT_TAKE12("Alias", add_alias, NULL, RSRC_CONF | ACCESS_CONF,
|
||||
"a fakename and a realname, or a realname in a Location"),
|
||||
AP_INIT_TAKE12("ScriptAlias", add_alias, "cgi-script", RSRC_CONF | ACCESS_CONF,
|
||||
"a fakename and a realname, or a realname in a Location"),
|
||||
AP_INIT_TAKE123("Redirect", add_redirect, (void *) HTTP_MOVED_TEMPORARILY,
|
||||
OR_FILEINFO,
|
||||
"an optional status, then document to be redirected and "
|
||||
"destination URL"),
|
||||
AP_INIT_TAKE2("AliasMatch", add_alias_regex, NULL, RSRC_CONF,
|
||||
"a regular expression and a filename"),
|
||||
AP_INIT_TAKE2("ScriptAliasMatch", add_alias_regex, "cgi-script", RSRC_CONF,
|
||||
"a regular expression and a filename"),
|
||||
AP_INIT_TAKE23("RedirectMatch", add_redirect_regex,
|
||||
(void *) HTTP_MOVED_TEMPORARILY, OR_FILEINFO,
|
||||
"an optional status, then a regular expression and "
|
||||
"destination URL"),
|
||||
AP_INIT_TAKE2("RedirectTemp", add_redirect2,
|
||||
(void *) HTTP_MOVED_TEMPORARILY, OR_FILEINFO,
|
||||
"a document to be redirected, then the destination URL"),
|
||||
AP_INIT_TAKE2("RedirectPermanent", add_redirect2,
|
||||
(void *) HTTP_MOVED_PERMANENTLY, OR_FILEINFO,
|
||||
"a document to be redirected, then the destination URL"),
|
||||
{NULL}
|
||||
};
|
||||
|
||||
|
||||
static void register_hooks(apr_pool_t *p)
|
||||
{
|
||||
static const char * const aszSucc[]={ "mod_userdir.c",
|
||||
|
||||
@@ -983,7 +983,7 @@ static int apprentice(server_rec *s, apr_pool_t *p)
|
||||
|
||||
#if MIME_MAGIC_DEBUG
|
||||
ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, s, APLOGNO(01516)
|
||||
MODNAME ": apprentice conf=%x file=%s m=%s m->next=%s last=%s",
|
||||
MODNAME ": apprentice conf=%pp file=%s m=%s m->next=%s last=%s",
|
||||
conf,
|
||||
conf->magicfile ? conf->magicfile : "NULL",
|
||||
conf->magic ? "set" : "NULL",
|
||||
@@ -1275,7 +1275,7 @@ static int parse(server_rec *serv, apr_pool_t *p, char *l, int lineno)
|
||||
|
||||
#if MIME_MAGIC_DEBUG
|
||||
ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, serv, APLOGNO(01525)
|
||||
MODNAME ": parse line=%d m=%x next=%x cont=%d desc=%s",
|
||||
MODNAME ": parse line=%d m=%pp next=%pp cont=%d desc=%s",
|
||||
lineno, m, m->next, m->cont_level, m->desc);
|
||||
#endif /* MIME_MAGIC_DEBUG */
|
||||
|
||||
@@ -1540,7 +1540,7 @@ static int match(request_rec *r, unsigned char *s, apr_size_t nbytes)
|
||||
|
||||
#if MIME_MAGIC_DEBUG
|
||||
ap_log_rerror(APLOG_MARK, APLOG_DEBUG, 0, r, APLOGNO(01529)
|
||||
MODNAME ": match conf=%x file=%s m=%s m->next=%s last=%s",
|
||||
MODNAME ": match conf=%pp file=%s m=%s m->next=%s last=%s",
|
||||
conf,
|
||||
conf->magicfile ? conf->magicfile : "NULL",
|
||||
conf->magic ? "set" : "NULL",
|
||||
@@ -1590,7 +1590,7 @@ static int match(request_rec *r, unsigned char *s, apr_size_t nbytes)
|
||||
#if MIME_MAGIC_DEBUG
|
||||
rule_counter++;
|
||||
ap_log_rerror(APLOG_MARK, APLOG_DEBUG, 0, r, APLOGNO(01532)
|
||||
MODNAME ": line=%d mc=%x mc->next=%x cont=%d desc=%s",
|
||||
MODNAME ": line=%d mc=%pp mc->next=%pp cont=%d desc=%s",
|
||||
m_cont->lineno, m_cont,
|
||||
m_cont->next, m_cont->cont_level,
|
||||
m_cont->desc);
|
||||
|
||||
@@ -284,10 +284,9 @@ static void *make_cookie_dir(apr_pool_t *p, char *d)
|
||||
|
||||
dcfg = (cookie_dir_rec *) apr_pcalloc(p, sizeof(cookie_dir_rec));
|
||||
dcfg->cookie_name = COOKIE_NAME;
|
||||
dcfg->cookie_domain = NULL;
|
||||
dcfg->style = CT_UNSET;
|
||||
dcfg->enabled = 0;
|
||||
/* calloc'ed to disabled: samesite, is_secure, is_httponly */
|
||||
/* calloc'ed to disabled: enabled, cookie_domain, samesite, is_secure,
|
||||
* is_httponly */
|
||||
|
||||
/* In case the user does not use the CookieName directive,
|
||||
* we need to compile the regexp for the default cookie name. */
|
||||
@@ -296,14 +295,6 @@ static void *make_cookie_dir(apr_pool_t *p, char *d)
|
||||
return dcfg;
|
||||
}
|
||||
|
||||
static const char *set_cookie_enable(cmd_parms *cmd, void *mconfig, int arg)
|
||||
{
|
||||
cookie_dir_rec *dcfg = mconfig;
|
||||
|
||||
dcfg->enabled = arg;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static const char *set_cookie_exp(cmd_parms *parms, void *dummy,
|
||||
const char *arg)
|
||||
{
|
||||
@@ -480,7 +471,8 @@ static const command_rec cookie_log_cmds[] = {
|
||||
"domain to which this cookie applies"),
|
||||
AP_INIT_TAKE1("CookieStyle", set_cookie_style, NULL, OR_FILEINFO,
|
||||
"'Netscape', 'Cookie' (RFC2109), or 'Cookie2' (RFC2965)"),
|
||||
AP_INIT_FLAG("CookieTracking", set_cookie_enable, NULL, OR_FILEINFO,
|
||||
AP_INIT_FLAG("CookieTracking", ap_set_flag_slot,
|
||||
(void *)APR_OFFSETOF(cookie_dir_rec, enabled), OR_FILEINFO,
|
||||
"whether or not to enable cookies"),
|
||||
AP_INIT_TAKE1("CookieName", set_cookie_name, NULL, OR_FILEINFO,
|
||||
"name of the tracking cookie"),
|
||||
|
||||
@@ -31,9 +31,9 @@ PROXY_DECLARE(int) ap_proxy_is_domainname(struct dirconn_entry *This, apr_pool_t
|
||||
PROXY_DECLARE(int) ap_proxy_is_hostname(struct dirconn_entry *This, apr_pool_t *p);
|
||||
PROXY_DECLARE(int) ap_proxy_is_word(struct dirconn_entry *This, apr_pool_t *p);
|
||||
|
||||
PROXY_DECLARE_DATA extern int proxy_lb_workers;
|
||||
PROXY_DECLARE_DATA extern const apr_strmatch_pattern *ap_proxy_strmatch_path;
|
||||
PROXY_DECLARE_DATA extern const apr_strmatch_pattern *ap_proxy_strmatch_domain;
|
||||
extern PROXY_DECLARE_DATA int proxy_lb_workers;
|
||||
extern PROXY_DECLARE_DATA const apr_strmatch_pattern *ap_proxy_strmatch_path;
|
||||
extern PROXY_DECLARE_DATA const apr_strmatch_pattern *ap_proxy_strmatch_domain;
|
||||
|
||||
/**
|
||||
* Register optional functions declared within proxy_util.c.
|
||||
|
||||
@@ -269,7 +269,7 @@ cmd_modem_standard(cmd_parms *cmd,
|
||||
}
|
||||
|
||||
if (dcfg->bytes_per_second == 0) {
|
||||
return "mod_diaulup: Unknown Modem Standard specified.";
|
||||
return "mod_dialup: Unknown Modem Standard specified.";
|
||||
}
|
||||
|
||||
return NULL;
|
||||
|
||||
@@ -341,8 +341,10 @@ static int log_child(apr_pool_t *p, const char *progname,
|
||||
rc = apr_procattr_child_err_set(procattr, errfile, NULL);
|
||||
}
|
||||
|
||||
rc = apr_proc_create(procnew, args[0], (const char * const *)args,
|
||||
NULL, procattr, p);
|
||||
if (rc == APR_SUCCESS) {
|
||||
rc = apr_proc_create(procnew, args[0], (const char * const *)args,
|
||||
NULL, procattr, p);
|
||||
}
|
||||
|
||||
if (rc == APR_SUCCESS) {
|
||||
apr_pool_note_subprocess(p, procnew, APR_KILL_AFTER_TIMEOUT);
|
||||
|
||||
@@ -586,10 +586,10 @@ static int create_process(apr_pool_t *p, HANDLE *child_proc, HANDLE *child_exit_
|
||||
return -1;
|
||||
}
|
||||
|
||||
args = malloc((ap_server_conf->process->argc + 1) * sizeof (char*));
|
||||
args = ap_malloc((ap_server_conf->process->argc + 1) * sizeof (char*));
|
||||
memcpy(args + 1, ap_server_conf->process->argv + 1,
|
||||
(ap_server_conf->process->argc - 1) * sizeof (char*));
|
||||
args[0] = malloc(strlen(cmd) + 1);
|
||||
args[0] = ap_malloc(strlen(cmd) + 1);
|
||||
strcpy(args[0], cmd);
|
||||
args[ap_server_conf->process->argc] = NULL;
|
||||
}
|
||||
|
||||
@@ -901,7 +901,7 @@ rrl_done:
|
||||
else if (deferred_error == rrl_excesswhitespace)
|
||||
ap_log_rerror(APLOG_MARK, APLOG_DEBUG, 0, r, APLOGNO(03448)
|
||||
"HTTP Request Line; Excess whitespace "
|
||||
"(disallowed by HttpProtocolOptions Strict");
|
||||
"(disallowed by HttpProtocolOptions Strict)");
|
||||
else if (deferred_error == rrl_trailingtext)
|
||||
ap_log_rerror(APLOG_MARK, APLOG_DEBUG, 0, r, APLOGNO(03449)
|
||||
"HTTP Request Line; Extraneous text found '%.*s' "
|
||||
|
||||
Reference in New Issue
Block a user