X-Git-Url: http://git.rohieb.name/openwrt.git/blobdiff_plain/b5cb1795de1f0959de1e228bd2e784d1cea921a7..ba43ecdcd5b3c047e9722b5b29c8aa1357e3f218:/package/busybox/patches/440-httpd_chdir.patch diff --git a/package/busybox/patches/440-httpd_chdir.patch b/package/busybox/patches/440-httpd_chdir.patch index 8ef70b84d..e7ae3bca7 100644 --- a/package/busybox/patches/440-httpd_chdir.patch +++ b/package/busybox/patches/440-httpd_chdir.patch @@ -1,29 +1,12 @@ -Index: busybox-1.4.2/networking/httpd.c +Index: busybox-1.7.2/networking/httpd.c =================================================================== ---- busybox-1.4.2.orig/networking/httpd.c 2007-06-04 13:21:35.775537960 +0200 -+++ busybox-1.4.2/networking/httpd.c 2007-06-04 13:21:36.144481872 +0200 -@@ -102,6 +102,7 @@ - static const char default_path_httpd_conf[] = "/etc"; - static const char httpd_conf[] = "httpd.conf"; - static const char home[] = "./"; -+static const char *home_httpd = home; - - #define TIMEOUT 60 - -@@ -1505,6 +1506,8 @@ +--- busybox-1.7.2.orig/networking/httpd.c 2007-10-30 15:35:04.000000000 -0500 ++++ busybox-1.7.2/networking/httpd.c 2007-10-30 15:35:04.000000000 -0500 +@@ -1618,6 +1618,7 @@ #if ENABLE_FEATURE_HTTPD_BASIC_AUTH int credentials = -1; /* if not required this is Ok */ #endif -+ + xchdir(home_httpd); - sa.sa_handler = handle_sigalrm; - sigemptyset(&sa.sa_mask); -@@ -1942,7 +1945,6 @@ - int httpd_main(int argc, char *argv[]) - { - unsigned opt; -- const char *home_httpd = home; - char *url_for_decode; - USE_FEATURE_HTTPD_ENCODE_URL_STR(const char *url_for_encode;) - const char *s_port; + /* Allocation of iobuf is postponed until now + * (IOW, server process doesn't need to waste 8k) */