diff options
author | Denis Vlasenko | 2006-10-07 16:24:46 +0000 |
---|---|---|
committer | Denis Vlasenko | 2006-10-07 16:24:46 +0000 |
commit | 5625415085e68ac5e150f54e685417c866620d76 (patch) | |
tree | 4146667d4080f97bc39ac96d844c01a8956aeeca /networking/httpd.c | |
parent | 890ac9deb2cc57cadd7aba4ee91bd012e19e239d (diff) | |
download | busybox-5625415085e68ac5e150f54e685417c866620d76.zip busybox-5625415085e68ac5e150f54e685417c866620d76.tar.gz |
dd: make it recognize not only 'k' but 'K' too;
make it (partially) CONFIG_LFS-aware
Diffstat (limited to 'networking/httpd.c')
-rw-r--r-- | networking/httpd.c | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/networking/httpd.c b/networking/httpd.c index 8f98577..0e471ba 100644 --- a/networking/httpd.c +++ b/networking/httpd.c @@ -97,14 +97,6 @@ static const char default_path_httpd_conf[] = "/etc"; static const char httpd_conf[] = "httpd.conf"; static const char home[] = "./"; -#if ENABLE_LFS -# define cont_l_fmt "%lld" -# define cont_l_type (long long) -#else -# define cont_l_fmt "%ld" -# define cont_l_type (long) -#endif - #define TIMEOUT 60 // Note: busybox xfuncs are not used because we want the server to keep running @@ -927,8 +919,8 @@ static int sendHeaders(HttpResponseNum responseNum) if (config->ContentLength != -1) { /* file */ strftime(timeStr, sizeof(timeStr), RFC1123FMT, gmtime(&config->last_mod)); - len += sprintf(buf+len, "Last-Modified: %s\r\n%s " cont_l_fmt "\r\n", - timeStr, Content_length, cont_l_type config->ContentLength); + len += sprintf(buf+len, "Last-Modified: %s\r\n%s "FILEOFF_FMT"\r\n", + timeStr, Content_length, (FILEOFF_TYPE) config->ContentLength); } strcat(buf, "\r\n"); len += 2; |