mod_bw.c : error remote_addr


# apxs -i -a -c mod_bw.c
/usr/lib64/apr-1/build/libtool --silent --mode=compile gcc -std=gnu99 -prefer-pic -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -DLINUX -D_REENTRANT -D_GNU_SOURCE -pthread -I/usr/include/httpd -I/usr/include/apr-1 -I/usr/include/apr-1 -c -o mod_bw.lo mod_bw.c && touch mod_bw.slo
mod_bw.c: In function 'get_bw_rate':
mod_bw.c:567:59: error: 'conn_rec' has no member named 'remote_addr'
if (apr_ipsubnet_test(e[i].x.ip, r->connection->remote_addr)) {
^
mod_bw.c: In function 'get_maxconn':
mod_bw.c:658:59: error: 'conn_rec' has no member named 'remote_addr'
if (apr_ipsubnet_test(e[i].x.ip, r->connection->remote_addr)) {
^
mod_bw.c: In function 'get_sid':
mod_bw.c:709:59: error: 'conn_rec' has no member named 'remote_addr'
if (apr_ipsubnet_test(e[i].x.ip, r->connection->remote_addr)) {

# cp mod_bw.c mod_bw.c.org
# sed s/remote_addr/client_addr/g -i mod_bw.c
# apxs -i -a -c mod_bw.c
Libraries have been installed in:
/usr/lib64/httpd/modules

If you ever happen to want to link against installed libraries
in a given directory, LIBDIR, you must either use libtool, and
specify the full pathname of the library, or use the `-LLIBDIR'
flag during linking and do at least one of the following:
- add LIBDIR to the `LD_LIBRARY_PATH' environment variable
during execution
- add LIBDIR to the `LD_RUN_PATH' environment variable
during linking
- use the `-Wl,-rpath -Wl,LIBDIR' linker flag
- have your system administrator add LIBDIR to `/etc/ld.so.conf'

See any operating system documentation about shared libraries for
more information, such as the ld(1) and ld.so(8) manual pages.
----------------------------------------------------------------------
chmod 755 /usr/lib64/httpd/modules/mod_bw.so
[activating module `bw' in /etc/httpd/conf/httpd.conf]