From c05d77e2a5de77c718577a1b33e5e451afb8a39e Mon Sep 17 00:00:00 2001 From: Mathieu Arnold Date: Mon, 25 Aug 2014 15:02:11 +0000 Subject: Make the patch cleaner and always apply it. Sponsored by: Absolight --- www/mod_auth_xradius/Makefile | 8 +------- .../files/ap24-patch-src__xradius_cache.c | 14 -------------- .../files/patch-src__xradius_cache.c | 20 ++++++++++++++++++++ 3 files changed, 21 insertions(+), 21 deletions(-) delete mode 100644 www/mod_auth_xradius/files/ap24-patch-src__xradius_cache.c create mode 100644 www/mod_auth_xradius/files/patch-src__xradius_cache.c (limited to 'www/mod_auth_xradius') diff --git a/www/mod_auth_xradius/Makefile b/www/mod_auth_xradius/Makefile index 732cf360918a..17ac281e691f 100644 --- a/www/mod_auth_xradius/Makefile +++ b/www/mod_auth_xradius/Makefile @@ -18,10 +18,4 @@ GNU_CONFIGURE= yes PLIST_FILES= ${APACHEMODDIR}/mod_auth_xradius.so -.include - -.if ${APACHE_VERSION} > 22 -EXTRA_PATCHES= ${PATCHDIR}/ap24-patch-src__xradius_cache.c -.endif - -.include +.include diff --git a/www/mod_auth_xradius/files/ap24-patch-src__xradius_cache.c b/www/mod_auth_xradius/files/ap24-patch-src__xradius_cache.c deleted file mode 100644 index 31adbb885764..000000000000 --- a/www/mod_auth_xradius/files/ap24-patch-src__xradius_cache.c +++ /dev/null @@ -1,14 +0,0 @@ ---- ./src/xradius_cache.c.orig 2005-04-27 08:49:25.000000000 +0200 -+++ ./src/xradius_cache.c 2014-08-12 11:56:22.000000000 +0200 -@@ -143,9 +143,9 @@ - /* Running as Root */ - if (geteuid() == 0) { - /* Allow the configured Apache use to read/write to the DBM */ -- chown(path1, unixd_config.user_id, -1); -+ chown(path1, ap_unixd_config.user_id, -1); - if (path2 != NULL) { -- chown(path2, unixd_config.user_id, -1); -+ chown(path2, ap_unixd_config.user_id, -1); - } - } - #endif diff --git a/www/mod_auth_xradius/files/patch-src__xradius_cache.c b/www/mod_auth_xradius/files/patch-src__xradius_cache.c new file mode 100644 index 000000000000..6a2093b6f558 --- /dev/null +++ b/www/mod_auth_xradius/files/patch-src__xradius_cache.c @@ -0,0 +1,20 @@ +--- ./src/xradius_cache.c.orig 2005-04-27 08:49:25.000000000 +0200 ++++ ./src/xradius_cache.c 2014-08-25 17:00:48.000000000 +0200 +@@ -143,10 +143,17 @@ + /* Running as Root */ + if (geteuid() == 0) { + /* Allow the configured Apache use to read/write to the DBM */ ++#if MODULE_MAGIC_NUMBER_MAJOR >= 20111130 ++ chown(path1, ap_unixd_config.user_id, -1); ++ if (path2 != NULL) { ++ chown(path2, ap_unixd_config.user_id, -1); ++ } ++#else + chown(path1, unixd_config.user_id, -1); + if (path2 != NULL) { + chown(path2, unixd_config.user_id, -1); + } ++#endif + } + #endif + -- cgit v1.2.3