geolizer-2.01.10_p20070115-etc-geolizer-conf.patch 2.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. From 64325c4fed853418f75357e0bb78668f999478ab Mon Sep 17 00:00:00 2001
  2. From: Sebastian Pipping <sebastian@pipping.org>
  3. Date: Wed, 10 Mar 2010 16:55:28 +0100
  4. Subject: [PATCH] etc-eolizer-conf
  5. ---
  6. sample.conf | 4 ++--
  7. webalizer.1 | 6 +++---
  8. webalizer.c | 8 ++++----
  9. 3 files changed, 9 insertions(+), 9 deletions(-)
  10. diff --git a/sample.conf b/sample.conf
  11. index 9eaef68..1d0b048 100644
  12. --- a/sample.conf
  13. +++ b/sample.conf
  14. @@ -16,8 +16,8 @@
  15. # at least one space or tab between the keyword and its value.
  16. #
  17. # As of version 0.98, The Webalizer will look for a 'default' configuration
  18. -# file named "webalizer.conf" in the current directory, and if not found
  19. -# there, will look for "/etc/webalizer.conf".
  20. +# file named "geolizer.conf" in the current directory, and if not found
  21. +# there, will look for "/etc/geolizer.conf".
  22. # LogFile defines the web server log file to use. If not specified
  23. diff --git a/webalizer.1 b/webalizer.1
  24. index b810c1f..fe0a589 100644
  25. --- a/webalizer.1
  26. +++ b/webalizer.1
  27. @@ -43,9 +43,9 @@ as a \fBcrond(8)\fP job. Once executed, the general flow of the program is:
  28. .TP 8
  29. .B o
  30. A default configuration file is scanned for. A file named
  31. -\fIwebalizer.conf\fP is searched for in the current directory, and if
  32. +\fIgeolizer.conf\fP is searched for in the current directory, and if
  33. found, it's configuration data is parsed. If the file is not
  34. -present in the current directory, the file \fI/etc/webalizer.conf\fP
  35. +present in the current directory, the file \fI/etc/geolizer.conf\fP
  36. is searched for and, if found, is used instead.
  37. .TP 8
  38. .B o
  39. @@ -688,7 +688,7 @@ Specifies GeoIP database file. Defaults to libGeoIP precompiled one
  40. (normally \fI/usr/local/share/GeoIP/GeoIP.dat\fP).
  41. .SH FILES
  42. .TP 20
  43. -.I webalizer.conf
  44. +.I geolizer.conf
  45. Default configuration file. Is searched for in the current directory
  46. and if not found, in the \fI/etc/\fP directory.
  47. .TP 20
  48. diff --git a/webalizer.c b/webalizer.c
  49. index 2daad89..db7adb2 100644
  50. --- a/webalizer.c
  51. +++ b/webalizer.c
  52. @@ -278,9 +278,9 @@ int main(int argc, char *argv[])
  53. len = GetModuleFileName(GetModuleHandle(NULL), tmp_buf, sizeof(tmp_buf) - 1);
  54. for (p = tmp_buf + len; (p > tmp_buf) && (*p != '\\'); p--);
  55. *p = '\0';
  56. - strncat(tmp_buf, "\\webalizer.conf", sizeof(tmp_buf) - 1);
  57. + strncat(tmp_buf, "\\geolizer.conf", sizeof(tmp_buf) - 1);
  58. #else
  59. - sprintf(tmp_buf,"%s/webalizer.conf",ETCDIR);
  60. + sprintf(tmp_buf,"%s/geolizer.conf",ETCDIR);
  61. #endif /* WIN32 */
  62. /* initalize epoch */
  63. @@ -290,8 +290,8 @@ int main(int argc, char *argv[])
  64. add_nlist("index.",&index_alias);
  65. /* check for default config file */
  66. - if (!access("webalizer.conf",F_OK))
  67. - get_config("webalizer.conf");
  68. + if (!access("geolizer.conf",F_OK))
  69. + get_config("geolizer.conf");
  70. else if (!access(tmp_buf,F_OK))
  71. get_config(tmp_buf);
  72. --
  73. 1.7.0.1.61.gdc05d.dirty