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

57 Commits

Author SHA1 Message Date
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
Stefan Fritsch
61a0413706 Use APR_STATUS_IS_... in some more cases.
While this is not strictly necessary everywhere, it makes it much easier
to find the problematic cases.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1102124 13f79535-47bb-0310-9956-ffa450edef68
2011-05-11 22:51:46 +00:00
Jeff Trawick
782c711893 fix some dead assignments found by the clang analyzer
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1098162 13f79535-47bb-0310-9956-ffa450edef68
2011-04-30 21:18:58 +00:00
Guenter Knauf
922ce76037 Some more casts to make MSVC calm ...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1040791 13f79535-47bb-0310-9956-ffa450edef68
2010-11-30 21:59:01 +00:00
Guenter Knauf
c163534ebc Fixed return type to silent compiler warning.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1040733 13f79535-47bb-0310-9956-ffa450edef68
2010-11-30 19:48:06 +00:00
Graham Leggett
27637bfdd8 mod_disk_cache renamed to mod_cache_disk, to be consistent with the
naming of other modules.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1037229 13f79535-47bb-0310-9956-ffa450edef68
2010-11-20 14:58:34 +00:00
Stefan Fritsch
958d7a4b09 Remove workaround that was only necessary when htcacheclean included httpd.h
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1034018 13f79535-47bb-0310-9956-ffa450edef68
2010-11-11 18:09:06 +00:00
Guenter Knauf
ba6999ccef More splitting as suggested by minfrin.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1033952 13f79535-47bb-0310-9956-ffa450edef68
2010-11-11 14:41:32 +00:00
Guenter Knauf
c86bf4327d Splitted off cache defines/structs used by htcacheclean.
This makes htcacheclean again independent from httpd.h.
Submitted by: NormW <normw gknw net>


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1033779 13f79535-47bb-0310-9956-ffa450edef68
2010-11-10 23:43:06 +00:00
Stefan Fritsch
fccb8870c7 Fix compilation of htcacheclean with enable-maintainer-mode / AP_DEBUG
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1023939 13f79535-47bb-0310-9956-ffa450edef68
2010-10-18 18:33:49 +00:00
Graham Leggett
abf1b9da3c htcacheclean: Teach htcacheclean to limit cache size by number of
inodes in addition to size of files. Prevents a cache disk from
running out of space when many small files are cached.

Move the directory delete process to the "purge" section, so that
inode counts are accurate when querying for stats only.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1022230 13f79535-47bb-0310-9956-ffa450edef68
2010-10-13 18:41:56 +00:00
Graham Leggett
5c0b07953a Fix a segfault when tmpfiles are encountered while cleaning.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1004987 13f79535-47bb-0310-9956-ffa450edef68
2010-10-06 11:03:52 +00:00
Graham Leggett
a304385afa Ensure the correct pool is passed in when listing URLs.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1004641 13f79535-47bb-0310-9956-ffa450edef68
2010-10-05 13:52:37 +00:00
Graham Leggett
0509b44525 htcacheclean: Allow the listing of valid URLs within the cache, with
the option to list entry metadata such as sizes and times.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1004482 13f79535-47bb-0310-9956-ffa450edef68
2010-10-04 23:44:27 +00:00
Graham Leggett
a56a9e23e7 htcacheclean: Allow the option to round up file sizes to a given
block size, improving the accuracy of disk usage.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1002854 13f79535-47bb-0310-9956-ffa450edef68
2010-09-29 21:34:48 +00:00
Graham Leggett
2daba6a048 mod_disk_cache: Instead of creating an empty data file when the body is
empty, don't create a file at all, saving inodes.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1002832 13f79535-47bb-0310-9956-ffa450edef68
2010-09-29 20:00:11 +00:00
Graham Leggett
8dd0a17fa3 htcacheclean: If the cache file format is unrecognised, remove the entry
from the cache.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1002686 13f79535-47bb-0310-9956-ffa450edef68
2010-09-29 15:41:15 +00:00
Graham Leggett
e7f90638f7 htcacheclean: Introduce the ability to clean specific URLs from the
cache, if provided as an optional parameter on the command line.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@928921 13f79535-47bb-0310-9956-ffa450edef68
2010-03-29 22:30:46 +00:00
Graham Leggett
0cce5a90fc htcacheclean: Report additional statistics about entries deleted.
PR: 48944
Submitted by: Mark Drayton mark markdrayton.info


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@928223 13f79535-47bb-0310-9956-ffa450edef68
2010-03-27 16:31:56 +00:00
Graham Leggett
71b4ccfe5a Create the pidfile world readable by adding APR_FPROT_WREAD. Use
non-deprecated versions of the APR constants.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@917005 13f79535-47bb-0310-9956-ffa450edef68
2010-02-27 18:23:08 +00:00
Graham Leggett
302e2d7a21 Try open the pid file twice, once before daemonisation so we can see any
error, and once after daemonisation so the child's pid is logged correctly.
Patch by Jeff Trawick.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@917002 13f79535-47bb-0310-9956-ffa450edef68
2010-02-27 18:13:56 +00:00
Graham Leggett
55f3e48013 Make sure the pidfile is deleted on close.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@910756 13f79535-47bb-0310-9956-ffa450edef68
2010-02-16 23:09:50 +00:00
Graham Leggett
69eeef38cd Use APR_PID_T_FMT instead of %ld and a cast.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@910747 13f79535-47bb-0310-9956-ffa450edef68
2010-02-16 22:57:00 +00:00
Graham Leggett
99163014c5 Fix the help description.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@910735 13f79535-47bb-0310-9956-ffa450edef68
2010-02-16 22:25:34 +00:00
Graham Leggett
1a647a2723 support/htcacheclean: Teach it how to write a pid file (modelled on
httpd's writing of a pid file) so that it becomes possible to run
more than one instance of htcacheclean on the same machine.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@910705 13f79535-47bb-0310-9956-ffa450edef68
2010-02-16 21:42:03 +00:00
Jeff Trawick
d854b9d90c fix or complain about some invalid errno references
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@882269 13f79535-47bb-0310-9956-ffa450edef68
2009-11-19 20:00:12 +00:00
Daniel Earl Poirier
ccad0563f8 Detab.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@816701 13f79535-47bb-0310-9956-ffa450edef68
2009-09-18 16:26:55 +00:00
Jeff Trawick
880de39ad7 simplify reporting of the repeated argument error
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@815448 13f79535-47bb-0310-9956-ffa450edef68
2009-09-15 18:59:52 +00:00
Graham Leggett
ba3cb779ab Move declaration to remove a compiler warning.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@814779 13f79535-47bb-0310-9956-ffa450edef68
2009-09-14 19:06:36 +00:00
Ruediger Pluem
4c92520eb6 * Detab.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@814113 13f79535-47bb-0310-9956-ffa450edef68
2009-09-12 07:57:59 +00:00
Graham Leggett
044592bfa1 htcacheclean: 19 ways to fail, 1 error message. Fixed.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@814091 13f79535-47bb-0310-9956-ffa450edef68
2009-09-11 23:57:48 +00:00
Ruediger Pluem
24715bae60 * The header file is still needed in this case. So prevent it from being
deleted.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@731535 13f79535-47bb-0310-9956-ffa450edef68
2009-01-05 11:52:05 +00:00
Ruediger Pluem
924cc6d6f3 * Fix style by doing correct indenting
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@656413 13f79535-47bb-0310-9956-ffa450edef68
2008-05-14 20:26:35 +00:00
Paul Querna
590c6ee637 Check return value of apr_file_read_full.
Reported By: BOYA SUN <boya.sun case.edu>


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@656401 13f79535-47bb-0310-9956-ffa450edef68
2008-05-14 20:14:29 +00:00
Nick Kew
e5061abc93 Multiple trivial fixes from Christophe JAILLET
PR 38699, 39518, 42005, 42006, 42007, 42008, 42009
The patches are all his, and are sufficiently trivial to review
at a glance.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@557837 13f79535-47bb-0310-9956-ffa450edef68
2007-07-20 01:26:55 +00:00
Graham Leggett
4fdaeae371 Add a missing include of apr_buckets.h. [Martin Kraemer]
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@464638 13f79535-47bb-0310-9956-ffa450edef68
2006-10-16 19:40:32 +00:00
Roy T. Fielding
de659cbed0 update license header text
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@420983 13f79535-47bb-0310-9956-ffa450edef68
2006-07-11 20:33:53 +00:00
Colm MacCarthaigh
dd95d7c37c Update the copyright year in all .c, .h and .xml files
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@395228 13f79535-47bb-0310-9956-ffa450edef68
2006-04-19 12:11:27 +00:00
Jim Jagielski
5061d9fa92 No functional Change: Removing trailing whitespace. This also
means that "blank" lines consisting of just spaces or
tabs are now really blank lines


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@332306 13f79535-47bb-0310-9956-ffa450edef68
2005-11-10 15:11:44 +00:00
Jim Jagielski
5d2fae4818 No functional change: simple detabbing of indented code.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@332305 13f79535-47bb-0310-9956-ffa450edef68
2005-11-10 15:05:51 +00:00
Colm MacCarthaigh
42377545e2 Allow htcacheclean to deal in gigabytes.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@240297 13f79535-47bb-0310-9956-ffa450edef68
2005-08-26 17:54:18 +00:00
Colm MacCarthaigh
275c89cda8 Add APR_FOPEN_BINARY to the options passed to apr for opening the
cache header files.



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@239436 13f79535-47bb-0310-9956-ffa450edef68
2005-08-23 17:03:01 +00:00
Andreas Steinmetz
59a68232cc Split mod_disk_cache.c into mod_disk_cache.c and mod_disk_cache.h
to allow inclusion of mod_disk_cache.h in htcacheclean.c.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@239406 13f79535-47bb-0310-9956-ffa450edef68
2005-08-23 13:35:00 +00:00
Colm MacCarthaigh
7482daa131 Update htcacheclean defines to match mod_disk_cache.c, Andreas is working on
mod_disk_cache.h, an all-round better solution, but for now just fix the
bug.



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@239381 13f79535-47bb-0310-9956-ffa450edef68
2005-08-23 09:25:31 +00:00
Joe Orton
1e9e5a69cb * support/htcacheclean.c (directory_empty): Remove unused function.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@232218 13f79535-47bb-0310-9956-ffa450edef68
2005-08-12 06:38:01 +00:00
Justin Erenkrantz
c5db9990f3 Add -t option to htcacheclean to clean out empty directories.
* support/htcacheclean.c: Implement -t option.
* docs/man/htcacheclean.8, docs/manual/programs/htcacheclean.html.en,
  docs/manual/programs/htcacheclean.xml: Document -t option.

Justin did some minor tweaks as he agrees with Andreas and Rudiger that
apr_dir_remove should return an error if the directory isn't empty; hence,
remove the apr_dir_read calls.

Submitted by: Colm MacCarthaigh
Reviewed by:  Justin Erenkrantz, Andreas Steinmetz, Rudiger Pluem


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@231351 13f79535-47bb-0310-9956-ffa450edef68
2005-08-10 23:14:57 +00:00
Paul Querna
03bf1c3436 - Bring htcacheclean into sync with mod_disk_cache. It now has a very basic understanding of the Varied Headers file format, and will cleanup orphaned data files, or Vary Header Files that have expired.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@190537 13f79535-47bb-0310-9956-ffa450edef68
2005-06-14 00:27:01 +00:00
Justin Erenkrantz
905cdf9f0b Update copyright year to 2005 and standardize on current copyright owner line.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@151408 13f79535-47bb-0310-9956-ffa450edef68
2005-02-04 20:28:49 +00:00
Jim Jagielski
bfb4758bf3 avoid vim autoindent :)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@111520 13f79535-47bb-0310-9956-ffa450edef68
2004-12-10 16:49:16 +00:00
Jim Jagielski
07e0b89c3b Dangerous assumption, especially if apr_dir_read uses readdir_r.
Be safe.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@111516 13f79535-47bb-0310-9956-ffa450edef68
2004-12-10 15:54:17 +00:00