1
0
mirror of https://github.com/apache/httpd.git synced 2025-11-05 05:30:39 +03:00
Commit Graph

497 Commits

Author SHA1 Message Date
Graham Leggett
26559c25c5 mod_cache: Remove ap_cache_liststr(), it duplicates ap_find_token().
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1209798 13f79535-47bb-0310-9956-ffa450edef68
2011-12-03 00:31:53 +00:00
Stefan Fritsch
92e366007c Add lots of unique tags to error log messages
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1209766 13f79535-47bb-0310-9956-ffa450edef68
2011-12-02 23:02:04 +00:00
Graham Leggett
d0d00b5d01 mod_cache: Apply the API change that allows future mod_cache providers to
invalidate cache entries, which will fix PR15868.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1208822 13f79535-47bb-0310-9956-ffa450edef68
2011-11-30 21:56:11 +00:00
Guenter Knauf
862faade75 Fixed compilation for non-*nix platforms.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1208527 13f79535-47bb-0310-9956-ffa450edef68
2011-11-30 17:16:09 +00:00
Stefan Fritsch
b4ec041ba7 Remove more log message prefixes that are now redundant as the
the error log format includes the module name.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1208110 13f79535-47bb-0310-9956-ffa450edef68
2011-11-29 22:28:21 +00:00
Stefan Fritsch
3c0136afce Fix some warn_unused_result compiler warnings by checking the return code of
chown and logging an error if the error was not ENOENT.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1206827 13f79535-47bb-0310-9956-ffa450edef68
2011-11-27 20:26:49 +00:00
Jim Jagielski
f66d79b8b2 Use varargs...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1205894 13f79535-47bb-0310-9956-ffa450edef68
2011-11-24 15:53:16 +00:00
Jim Jagielski
bf2fc8ee54 Use ap_pass_brigade_fchk()
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1205423 13f79535-47bb-0310-9956-ffa450edef68
2011-11-23 15:01:42 +00:00
Graham Leggett
78e657406b mod_cache_disk: Make sure we check return codes on all writes and attempts
to close, and clean up after ourselves in these cases. PR43589.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1204599 13f79535-47bb-0310-9956-ffa450edef68
2011-11-21 17:06:15 +00:00
Jim Jagielski
0871cc77f8 value never used: dead assignment
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1204555 13f79535-47bb-0310-9956-ffa450edef68
2011-11-21 15:51:44 +00:00
Graham Leggett
4ed1b41510 mod_cache_disk: Remove the unnecessary intermediate brigade while writing
to disk. Fixes a problem where mod_disk_cache was leaving buckets in the
intermediate brigade and not passing them to out on exit.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1204101 13f79535-47bb-0310-9956-ffa450edef68
2011-11-19 22:37:55 +00:00
Graham Leggett
d4780b88c9 mod_cache: Make sure we merge headers correctly when we handle a non
cacheable conditional response. PR52120.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1201331 13f79535-47bb-0310-9956-ffa450edef68
2011-11-12 21:24:47 +00:00
Stefan Fritsch
b5aafabf63 Consistently use base 10 for numbers when parsing config options. It may be
confusing to the user if some directives treat a number with leading zero as
octal while most don't.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1180687 13f79535-47bb-0310-9956-ffa450edef68
2011-10-09 18:58:21 +00:00
Stefan Fritsch
5c005263d5 Fix a potential NULL pointer dereference found by clang.
Add a AP_DEBUG_ASSERT to quiet a clang false positive.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1180329 13f79535-47bb-0310-9956-ffa450edef68
2011-10-08 07:41:50 +00:00
Stefan Fritsch
1951a037bf More cleanup: Expand tabs and some more indentation fixes
No functional change


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1174929 13f79535-47bb-0310-9956-ffa450edef68
2011-09-23 18:08:42 +00:00
Jim Jagielski
427c85bd23 Cleanup effort in prep for GA push:
Trim trailing whitespace... no func change



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1174751 13f79535-47bb-0310-9956-ffa450edef68
2011-09-23 13:39:32 +00:00
Jim Jagielski
103f776c25 Cleanup effort in prep for GA push:
Trim trailing whitespace... no func change



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1174748 13f79535-47bb-0310-9956-ffa450edef68
2011-09-23 13:38:09 +00:00
Stefan Fritsch
01ed21af9d Add wrappers for malloc, calloc, realloc that check for out of memory
situations.  Use them in most places where malloc, and friends are used.
This results in clean error messages in an out of memory situation instead of
segfaulting or silently malfunctioning. In some places, it just allows to
remove some logging code.

PR 51568, PR 51569, PR 51571.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1172686 13f79535-47bb-0310-9956-ffa450edef68
2011-09-19 16:25:42 +00:00
Graham Leggett
1d8184a974 mod_cache: Ensure that CacheDisable can correctly appear within
a LocationMatch.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1158022 13f79535-47bb-0310-9956-ffa450edef68
2011-08-15 21:28:08 +00:00
Graham Leggett
c951f5e999 mod_cache: Fix the moving of the CACHE filter, which erroneously
stood down if the original filter was not added by configuration.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1157976 13f79535-47bb-0310-9956-ffa450edef68
2011-08-15 20:09:38 +00:00
Rainer Jung
9ed2afa2b9 Tolerate dependency checking failures in configure
for modules that have been enabled only implicitely.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1142892 13f79535-47bb-0310-9956-ffa450edef68
2011-07-05 05:31:22 +00:00
Rainer Jung
d37c52a6e4 Silence compiler warnings.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1142733 13f79535-47bb-0310-9956-ffa450edef68
2011-07-04 16:37:46 +00:00
Rainer Jung
1fa2322c04 1) Add --with-distcache to configure for choosing
the distcache installation directory.

2) Use correct build variable MOD_SOCACHE_DC_LDADD
instead of MOD_SOCACHE_LDADD in build macro.

Also made the macro a bit more consistent with the
SSL checking macro.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1142648 13f79535-47bb-0310-9956-ffa450edef68
2011-07-04 13:03:01 +00:00
Stefan Fritsch
f66af00c19 Avoid some memory allocations by using apr_table_setn where the string
arguments are const.

Submitted by: Christophe JAILLET <christophe jaillet wanadoo fr>
PR: 51357


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1135083 13f79535-47bb-0310-9956-ffa450edef68
2011-06-13 10:58:10 +00:00
Graham Leggett
26f144c3d2 mod_cache: Ensure that r->content_type is set when serving stale
content in response to a failed attempt to revalidate.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1132816 13f79535-47bb-0310-9956-ffa450edef68
2011-06-06 22:44:31 +00:00
Stefan Fritsch
c9fd2623da Introduce ap_(get|set)_core_module_config() functions/macros and use them
everywhere.

We know that the core module has module_index 0. Therefore we can save
some pointer operations in ap_get_module_config(cv, &core_module) and
ap_set_module_config(cv, &core_module, val). As these are called rather often,
this may actually have some (small) measurable effect.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1132781 13f79535-47bb-0310-9956-ffa450edef68
2011-06-06 21:26:56 +00:00
Graham Leggett
f23aeced40 mod_cache: Clarify which scenario we have present, quick handler on and CACHE
filter present, which is an error, or the CACHE filter being present when the
cache is bypassed, which is business as usual.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1126575 13f79535-47bb-0310-9956-ffa450edef68
2011-05-23 16:41:00 +00:00
Graham Leggett
ef3dbf5cbd Both lastmod and lastmods resolve to 0 when unset, but only lastmods is a
pointer. Fix comparison between apr_time_t and NULL.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1103850 13f79535-47bb-0310-9956-ffa450edef68
2011-05-16 19:25:07 +00:00
Graham Leggett
e4133460ec mod_cache: When content is served stale, and there is no means to
revalidate the content using ETag or Last-Modified, and we have
mandated no stale-on-error behaviour, stand down and don't cache.
Saves a cache write that will never be read.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1103494 13f79535-47bb-0310-9956-ffa450edef68
2011-05-15 18:15:48 +00:00
Stefan Fritsch
2014acf62f Improvements found by cppcheck:
remove some unused variables and dead assignments, reduce the scope of some
variables, add some parens to improve readability


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1103459 13f79535-47bb-0310-9956-ffa450edef68
2011-05-15 16:58:45 +00:00
Jeff Trawick
562c645ad6 change signed single-bit fields to unsigned
some of these were exposed to mods so the mmn is bumped, without
regard to whether any compiler will have to generate different
code


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1086662 13f79535-47bb-0310-9956-ffa450edef68
2011-03-29 18:20:52 +00:00
Jeff Trawick
ddf06604b5 enable DEFAULT_REL_RUNTIMEDIR on NetWare and Windows
this commit is missing the Windows and NetWare build
logic to copy the appropriate file to include/ap_config_layout.h


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1086073 13f79535-47bb-0310-9956-ffa450edef68
2011-03-27 23:51:18 +00:00
Jeff Trawick
bc956c30c3 fix doxygen warnings
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1086071 13f79535-47bb-0310-9956-ffa450edef68
2011-03-27 23:36:03 +00:00
Guenter Knauf
888ec80125 Use a var INSTALLBASE to simplify NetWare installation rules.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1082821 13f79535-47bb-0310-9956-ffa450edef68
2011-03-18 04:56:06 +00:00
Guenter Knauf
bab978c56e Use var for prelude so its possible to change it at one place.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1082811 13f79535-47bb-0310-9956-ffa450edef68
2011-03-18 03:09:27 +00:00
Graham Leggett
e8f8ab7863 mod_cache: Make CacheEnable and CacheDisable configurable per
directory in addition to per server, making them work from within
a LocationMatch.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1080834 13f79535-47bb-0310-9956-ffa450edef68
2011-03-12 01:15:28 +00:00
Jeff Trawick
4598f1a7d4 fix some grammar mistakes, mostly in comments
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1080821 13f79535-47bb-0310-9956-ffa450edef68
2011-03-12 00:35:39 +00:00
Guenter Knauf
e8c197fe7f Added mod_socache_memcache to NetWare build.
Submitted by normw gknw.net.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1080058 13f79535-47bb-0310-9956-ffa450edef68
2011-03-09 23:31:22 +00:00
Guenter Knauf
cc686f480d Removed wrong imports / modules from NetWare sochache makefiles.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1080045 13f79535-47bb-0310-9956-ffa450edef68
2011-03-09 22:42:19 +00:00
Guenter Knauf
e8a8becc0f NetWare build overhaul in order to compile on Linux.
Removed absolute paths to imp files.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1079487 13f79535-47bb-0310-9956-ffa450edef68
2011-03-08 18:59:02 +00:00
Guenter Knauf
46b7e1d210 NetWare build overhaul in order to compile on Linux.
Take 1.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1079407 13f79535-47bb-0310-9956-ffa450edef68
2011-03-08 16:04:40 +00:00
Graham Leggett
1bb3c4b8a9 mod_cache_disk: Prevent a segfault should we receive a further bucket after
we have committed the cached entry.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1078104 13f79535-47bb-0310-9956-ffa450edef68
2011-03-04 19:07:22 +00:00
Graham Leggett
d35c89b1e0 mod_cache_disk: Only attempt to commit to the initialisation if the attempt
to open the cache file was successful.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1078083 13f79535-47bb-0310-9956-ffa450edef68
2011-03-04 18:11:32 +00:00
Graham Leggett
11b28165af Don't skip the first character, as it may be a quote, which is handled
by the walk below.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1070699 13f79535-47bb-0310-9956-ffa450edef68
2011-02-14 23:54:14 +00:00
Jeff Trawick
063415fc4a fix theoretical const issue in call to strchr()
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1070627 13f79535-47bb-0310-9956-ffa450edef68
2011-02-14 19:47:31 +00:00
Graham Leggett
43fc2d47c7 mod_cache: When a request other than GET or HEAD arrives, we must
invalidate existing cache entities as per RFC2616 13.10. PR 15868.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1070179 13f79535-47bb-0310-9956-ffa450edef68
2011-02-13 02:03:29 +00:00
Graham Leggett
b591028272 mod_cache: Make sure that the moving of the CACHE filter to another
point within a subrequest is limited to affecting filters in that
subrequest only.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1070161 13f79535-47bb-0310-9956-ffa450edef68
2011-02-12 23:21:18 +00:00
Graham Leggett
11a01ec97a mod_cache: When a bad Expires date is present, we need to behave as if
the Expires is in the past, not as if the Expires is missing. PR 16521.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1070128 13f79535-47bb-0310-9956-ffa450edef68
2011-02-12 19:02:58 +00:00
Graham Leggett
bd9b56da19 mod_cache: We must ignore quoted-string values that appear in a
Cache-Control header. PR 50199.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1070075 13f79535-47bb-0310-9956-ffa450edef68
2011-02-12 13:08:57 +00:00
Graham Leggett
dd0370c5e2 mod_cache: Respect s-maxage as described by RFC2616 14.9.3, which must
take precedence if present. PR 35247.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1069942 13f79535-47bb-0310-9956-ffa450edef68
2011-02-11 20:12:39 +00:00