]> git.pld-linux.org Git - packages/apache-mod_bw.git/commitdiff
- build with apache 2.4 master auto/th/apache-mod_bw-0.92-5
authorJan Rękorajski <baggins@pld-linux.org>
Sun, 5 May 2013 18:13:39 +0000 (20:13 +0200)
committerJan Rękorajski <baggins@pld-linux.org>
Sun, 5 May 2013 18:13:39 +0000 (20:13 +0200)
- rel 5

apache-mod_bw.spec
mod_bw-apache24.patch [new file with mode: 0644]

index 0cc9a44af5da9d3591ea03b8e7d2f47ba7f55cd1..0ec2915a75fcc7f1d8d9312f791797b1e2e463e6 100644 (file)
@@ -6,13 +6,14 @@ Summary:      Apache module: bandwidth limits
 Summary(pl.UTF-8):     Moduł do Apache: limity pasma
 Name:          apache-mod_%{mod_name}
 Version:       0.92
-Release:       4
+Release:       5
 License:       Apache v2.0
 Group:         Networking/Daemons/HTTP
 Source0:       http://ivn.cl/files/source/mod_bw-%{version}.tgz
 # Source0-md5: 90f5e632dad5de8d49dcdb61453dcf97
 Source1:       %{name}.conf
 Source2:       %{name}.tmpfiles
+Patch0:                mod_bw-apache24.patch
 URL:           http://www.ivn.cl/apache/
 BuildRequires: %{apxs}
 BuildRequires: apache-devel >= 2.0.0
@@ -37,6 +38,7 @@ katalogu, wielkości plików lub zdalnym IP/domenie.
 
 %prep
 %setup -qc
+%patch0 -p1
 
 %build
 %{apxs} -c mod_bw.c
diff --git a/mod_bw-apache24.patch b/mod_bw-apache24.patch
new file mode 100644 (file)
index 0000000..0d9e8c3
--- /dev/null
@@ -0,0 +1,31 @@
+diff --git a/mod_bw.c b/mod_bw.c
+index a49caf8..8b75973 100644
+--- a/mod_bw.c
++++ b/mod_bw.c
+@@ -519,7 +519,7 @@ static long get_bw_rate(request_rec * r, apr_array_header_t * a)
+             return e[i].rate;
+         case T_IP:
+-            if (apr_ipsubnet_test(e[i].x.ip, r->connection->remote_addr)) {
++            if (apr_ipsubnet_test(e[i].x.ip, r->useragent_addr)) {
+                 return e[i].rate;
+             }
+             break;
+@@ -608,7 +608,7 @@ static int get_maxconn(request_rec * r, apr_array_header_t * a)
+             return e[i].max;
+         case T_IP:
+-            if (apr_ipsubnet_test(e[i].x.ip, r->connection->remote_addr)) {
++            if (apr_ipsubnet_test(e[i].x.ip, r->useragent_addr)) {
+                 return e[i].max;
+             }
+             break;
+@@ -659,7 +659,7 @@ static int get_sid(request_rec * r, apr_array_header_t * a)
+             return e[i].sid;
+         case T_IP:
+-            if (apr_ipsubnet_test(e[i].x.ip, r->connection->remote_addr)) {
++            if (apr_ipsubnet_test(e[i].x.ip, r->useragent_addr)) {
+                 return e[i].sid;
+             }
+             break;
This page took 0.069117 seconds and 4 git commands to generate.