[PATCH] tinyproxy: allow to use the bind option
Attached patch allows to use the 'bind' option even if transparent proxy support is compiled into tinyproxy (which is in openwrt). There are several references related to the bug, but nobody seams to know why this - apparently not needed - check was build in. Regards Mathias git-svn-id: svn://svn.openwrt.org/openwrt/packages@26982 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
@ -12,7 +12,7 @@
|
||||
ACLOCAL_AMFLAGS = -I m4macros
|
||||
--- a/Makefile.in
|
||||
+++ b/Makefile.in
|
||||
@@ -221,9 +221,7 @@ SUBDIRS = \
|
||||
@@ -222,9 +222,7 @@ SUBDIRS = \
|
||||
src \
|
||||
data \
|
||||
etc \
|
||||
|
@ -1,7 +1,6 @@
|
||||
diff -Nur a/src/main.c b/src/main.c
|
||||
--- a/src/main.c 2010-07-17 11:57:25.000000000 +0200
|
||||
+++ b/src/main.c 2010-07-17 11:58:52.000000000 +0200
|
||||
@@ -326,8 +326,8 @@
|
||||
--- a/src/main.c
|
||||
+++ b/src/main.c
|
||||
@@ -326,8 +326,8 @@ static void initialize_config_defaults (
|
||||
conf->errorpages = NULL;
|
||||
conf->stathost = safestrdup (TINYPROXY_STATHOST);
|
||||
conf->idletimeout = MAX_IDLE_TIME;
|
||||
@ -12,4 +11,3 @@ diff -Nur a/src/main.c b/src/main.c
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
|
@ -0,0 +1,22 @@
|
||||
--- a/src/conf.c
|
||||
+++ b/src/conf.c
|
||||
@@ -857,7 +857,6 @@ static HANDLE_FUNC (handle_deny)
|
||||
|
||||
static HANDLE_FUNC (handle_bind)
|
||||
{
|
||||
-#ifndef TRANSPARENT_PROXY
|
||||
int r = set_string_arg (&conf->bind_address, line, &match[2]);
|
||||
|
||||
if (r)
|
||||
@@ -865,11 +864,6 @@ static HANDLE_FUNC (handle_bind)
|
||||
log_message (LOG_INFO,
|
||||
"Outgoing connections bound to IP %s", conf->bind_address);
|
||||
return 0;
|
||||
-#else
|
||||
- fprintf (stderr,
|
||||
- "\"Bind\" cannot be used with transparent support enabled.\n");
|
||||
- return 1;
|
||||
-#endif
|
||||
}
|
||||
|
||||
static HANDLE_FUNC (handle_listen)
|
Reference in New Issue
Block a user