[-]
[+]
|
Changed |
busybox.spec
|
|
[-]
[+]
|
Deleted |
busybox-1.17.2-compat.patch
^
|
@@ -1,15 +0,0 @@
-diff -urpN busybox-1.17.2/networking/libiproute/iplink.c busybox-1.17.2-compat/networking/libiproute/iplink.c
---- busybox-1.17.2/networking/libiproute/iplink.c 2010-08-23 02:44:35.000000000 +0200
-+++ busybox-1.17.2-compat/networking/libiproute/iplink.c 2010-09-02 12:24:53.580708990 +0200
-@@ -15,6 +15,11 @@
- #include "rt_names.h"
- #include "utils.h"
-
-+#ifndef IFLA_LINKINFO
-+# define IFLA_LINKINFO 18
-+# define IFLA_INFO_KIND 1
-+#endif
-+
- /* taken from linux/sockios.h */
- #define SIOCSIFNAME 0x8923 /* set interface name */
-
|
[-]
[+]
|
Deleted |
busybox-1.17.2-hush.patch
^
|
@@ -1,122 +0,0 @@
-diff -urpN busybox-1.17.2/shell/hush.c busybox-1.17.2-hush/shell/hush.c
---- busybox-1.17.2/shell/hush.c 2010-08-23 02:45:15.000000000 +0200
-+++ busybox-1.17.2-hush/shell/hush.c 2010-09-04 19:44:57.381391123 +0200
-@@ -1853,7 +1853,7 @@ static void o_addblock_duplicate_backsla
- while (len) {
- o_addchr(o, *str);
- if (*str++ == '\\'
-- && (*str != '*' && *str != '?' && *str != '[')
-+// && (*str != '*' && *str != '?' && *str != '[')
- ) {
- o_addchr(o, '\\');
- }
-@@ -2834,18 +2834,22 @@ static NOINLINE int expand_vars_to_list(
- return n;
- }
-
--static char **expand_variables(char **argv, int or_mask)
-+enum {
-+ EXPVAR_FLAG_GLOB = 0x200,
-+ EXPVAR_FLAG_ESCAPE_VARS = 0x100,
-+ EXPVAR_FLAG_SINGLEWORD = 0x80, /* must be 0x80 */
-+};
-+static char **expand_variables(char **argv, unsigned or_mask)
- {
- int n;
- char **list;
- char **v;
- o_string output = NULL_O_STRING;
-
-- if (or_mask & 0x100) {
-- output.o_escape = 1; /* protect against globbing for "$var" */
-- /* (unquoted $var will temporarily switch it off) */
-- output.o_glob = 1;
-- }
-+ /* protect against globbing for "$var"? */
-+ /* (unquoted $var will temporarily switch it off) */
-+ output.o_escape = 1 & (or_mask / EXPVAR_FLAG_ESCAPE_VARS);
-+ output.o_glob = 1 & (or_mask / EXPVAR_FLAG_GLOB);
-
- n = 0;
- v = argv;
-@@ -2863,13 +2867,13 @@ static char **expand_variables(char **ar
-
- static char **expand_strvec_to_strvec(char **argv)
- {
-- return expand_variables(argv, 0x100);
-+ return expand_variables(argv, EXPVAR_FLAG_GLOB | EXPVAR_FLAG_ESCAPE_VARS);
- }
-
- #if ENABLE_HUSH_BASH_COMPAT
- static char **expand_strvec_to_strvec_singleword_noglob(char **argv)
- {
-- return expand_variables(argv, 0x80);
-+ return expand_variables(argv, EXPVAR_FLAG_SINGLEWORD);
- }
- #endif
-
-@@ -2909,15 +2913,15 @@ static char **expand_strvec_to_strvec_si
- #endif
-
- /* Used for expansion of right hand of assignments */
--/* NB: should NOT do globbing! "export v=/bin/c*; env | grep ^v=" outputs
-- * "v=/bin/c*" */
-+/* NB: should NOT do globbing!
-+ * "export v=/bin/c*; env | grep ^v=" outputs "v=/bin/c*" */
- static char *expand_string_to_string(const char *str)
- {
- char *argv[2], **list;
-
- argv[0] = (char*)str;
- argv[1] = NULL;
-- list = expand_variables(argv, 0x80); /* 0x80: singleword expansion */
-+ list = expand_variables(argv, EXPVAR_FLAG_ESCAPE_VARS | EXPVAR_FLAG_SINGLEWORD);
- if (HUSH_DEBUG)
- if (!list[0] || list[1])
- bb_error_msg_and_die("BUG in varexp2");
-@@ -2933,7 +2937,7 @@ static char* expand_strvec_to_string(cha
- {
- char **list;
-
-- list = expand_variables(argv, 0x80);
-+ list = expand_variables(argv, EXPVAR_FLAG_SINGLEWORD);
- /* Convert all NULs to spaces */
- if (list[0]) {
- int n = 1;
-diff -urpN busybox-1.17.2/shell/hush_test/hush-vars/var_unbackslash.right busybox-1.17.2-hush/shell/hush_test/hush-vars/var_unbackslash.right
---- busybox-1.17.2/shell/hush_test/hush-vars/var_unbackslash.right 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.17.2-hush/shell/hush_test/hush-vars/var_unbackslash.right 2010-09-04 19:44:57.382391186 +0200
-@@ -0,0 +1,9 @@
-+b1=-qwerty-t-\-"---z-*-?-
-+b1=-qwerty-t-\-"---z-*-?-
-+b2=-$a-\t-\\-\"-\--\z-\*-\?-
-+b2=-$a-\t-\\-\"-\--\z-\*-\?-
-+c=-$a-\t-\\-\"-\--\z-\*-\?-
-+c=-$a-\t-\\-\"-\--\z-\*-\?-
-+c=-$a-\t-\\-\"-\--\z-\*-\?-
-+c=-$a-\t-\\-\"-\--\z-\*-\?-
-+Done: 0
-diff -urpN busybox-1.17.2/shell/hush_test/hush-vars/var_unbackslash.tests busybox-1.17.2-hush/shell/hush_test/hush-vars/var_unbackslash.tests
---- busybox-1.17.2/shell/hush_test/hush-vars/var_unbackslash.tests 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.17.2-hush/shell/hush_test/hush-vars/var_unbackslash.tests 2010-09-04 19:44:57.382391186 +0200
-@@ -0,0 +1,20 @@
-+# Test for correct handling of backslashes
-+a=qwerty
-+
-+b=-$a-\t-\\-\"-\--\z-\*-\?-
-+echo b1=$b
-+echo "b1=$b"
-+b='-$a-\t-\\-\"-\--\z-\*-\?-'
-+echo b2=$b
-+echo "b2=$b"
-+
-+c=$b
-+echo "c=$c"
-+c=${b}
-+echo "c=$c"
-+c="$b"
-+echo "c=$c"
-+c="${b}"
-+echo "c=$c"
-+
-+echo "Done: $?"
|
[-]
[+]
|
Deleted |
busybox-1.17.2-lineedit.patch
^
|
@@ -1,504 +0,0 @@
-diff -urpN busybox-1.17.2/libbb/lineedit.c busybox-1.17.2-lineedit/libbb/lineedit.c
---- busybox-1.17.2/libbb/lineedit.c 2010-08-23 02:44:35.000000000 +0200
-+++ busybox-1.17.2-lineedit/libbb/lineedit.c 2010-09-07 18:33:16.337067116 +0200
-@@ -156,7 +156,6 @@ struct lineedit_statics {
-
- /* Formerly these were big buffers on stack: */
- #if ENABLE_FEATURE_TAB_COMPLETION
-- char exe_n_cwd_tab_completion__dirbuf[MAX_LINELEN];
- char input_tab__matchBuf[MAX_LINELEN];
- int16_t find_match__int_buf[MAX_LINELEN + 1]; /* need to have 9 bits at least */
- int16_t find_match__pos_buf[MAX_LINELEN + 1];
-@@ -235,6 +234,8 @@ static unsigned save_string(char *dst, u
- while (dstpos < maxsize) {
- wchar_t wc;
- int n = srcpos;
-+
-+ /* Convert up to 1st invalid byte (or up to end) */
- while ((wc = command_ps[srcpos]) != 0
- && !unicode_is_raw_byte(wc)
- ) {
-@@ -247,6 +248,7 @@ static unsigned save_string(char *dst, u
- dstpos += n;
- if (wc == 0) /* usually is */
- break;
-+
- /* We do have invalid byte here! */
- command_ps[srcpos] = wc; /* restore it */
- srcpos++;
-@@ -608,53 +610,56 @@ static void add_match(char *matched)
- }
-
- #if ENABLE_FEATURE_USERNAME_COMPLETION
--static void username_tab_completion(char *ud, char *with_shash_flg)
-+/* Replace "~user/..." with "/homedir/...".
-+ * The parameter is malloced, free it or return it
-+ * unchanged if no user is matched.
-+ */
-+static char *username_path_completion(char *ud)
- {
- struct passwd *entry;
-+ char *tilde_name = ud;
-+ char *home = NULL;
-+
-+ ud++; /* skip ~ */
-+ if (*ud == '/') { /* "~/..." */
-+ home = home_pwd_buf;
-+ } else {
-+ /* "~user/..." */
-+ ud = strchr(ud, '/');
-+ *ud = '\0'; /* "~user" */
-+ entry = getpwnam(tilde_name + 1);
-+ *ud = '/'; /* restore "~user/..." */
-+ if (entry)
-+ home = entry->pw_dir;
-+ }
-+ if (home) {
-+ ud = concat_path_file(home, ud);
-+ free(tilde_name);
-+ tilde_name = ud;
-+ }
-+ return tilde_name;
-+}
-+
-+/* ~use<tab> - find all users with this prefix */
-+static NOINLINE void username_completion(const char *ud)
-+{
-+ /* Using _r function to avoid pulling in static buffers */
-+ char line_buff[256];
-+ struct passwd pwd;
-+ struct passwd *result;
- int userlen;
-
-- ud++; /* ~user/... to user/... */
-+ ud++; /* skip ~ */
- userlen = strlen(ud);
-
-- if (with_shash_flg) { /* "~/..." or "~user/..." */
-- char *sav_ud = ud - 1;
-- char *home = NULL;
--
-- if (*ud == '/') { /* "~/..." */
-- home = home_pwd_buf;
-- } else {
-- /* "~user/..." */
-- char *temp;
-- temp = strchr(ud, '/');
-- *temp = '\0'; /* ~user\0 */
-- entry = getpwnam(ud);
-- *temp = '/'; /* restore ~user/... */
-- ud = temp;
-- if (entry)
-- home = entry->pw_dir;
-- }
-- if (home) {
-- if ((userlen + strlen(home) + 1) < MAX_LINELEN) {
-- /* /home/user/... */
-- sprintf(sav_ud, "%s%s", home, ud);
-- }
-- }
-- } else {
-- /* "~[^/]*" */
-- /* Using _r function to avoid pulling in static buffers */
-- char line_buff[256];
-- struct passwd pwd;
-- struct passwd *result;
--
-- setpwent();
-- while (!getpwent_r(&pwd, line_buff, sizeof(line_buff), &result)) {
-- /* Null usernames should result in all users as possible completions. */
-- if (/*!userlen || */ strncmp(ud, pwd.pw_name, userlen) == 0) {
-- add_match(xasprintf("~%s/", pwd.pw_name));
-- }
-+ setpwent();
-+ while (!getpwent_r(&pwd, line_buff, sizeof(line_buff), &result)) {
-+ /* Null usernames should result in all users as possible completions. */
-+ if (/*!userlen || */ strncmp(ud, pwd.pw_name, userlen) == 0) {
-+ add_match(xasprintf("~%s/", pwd.pw_name));
- }
-- endpwent();
- }
-+ endpwent();
- }
- #endif /* FEATURE_COMMAND_USERNAME_COMPLETION */
-
-@@ -664,22 +669,19 @@ enum {
- FIND_FILE_ONLY = 2,
- };
-
--static int path_parse(char ***p, int flags)
-+static int path_parse(char ***p)
- {
- int npth;
- const char *pth;
- char *tmp;
- char **res;
-
-- /* if not setenv PATH variable, to search cur dir "." */
-- if (flags != FIND_EXE_ONLY)
-- return 1;
--
- if (state->flags & WITH_PATH_LOOKUP)
- pth = state->path_lookup;
- else
- pth = getenv("PATH");
-- /* PATH=<empty> or PATH=:<empty> */
-+
-+ /* PATH="" or PATH=":"? */
- if (!pth || !pth[0] || LONE_CHAR(pth, ':'))
- return 1;
-
-@@ -689,12 +691,13 @@ static int path_parse(char ***p, int fla
- tmp = strchr(tmp, ':');
- if (!tmp)
- break;
-- if (*++tmp == '\0')
-+ tmp++;
-+ if (*tmp == '\0')
- break; /* :<empty> */
- npth++;
- }
-
-- res = xmalloc(npth * sizeof(char*));
-+ *p = res = xmalloc(npth * sizeof(res[0]));
- res[0] = tmp = xstrdup(pth);
- npth = 1;
- while (1) {
-@@ -706,100 +709,96 @@ static int path_parse(char ***p, int fla
- break; /* :<empty> */
- res[npth++] = tmp;
- }
-- *p = res;
- return npth;
- }
-
- static void exe_n_cwd_tab_completion(char *command, int type)
- {
-- DIR *dir;
-- struct dirent *next;
-- struct stat st;
- char *path1[1];
- char **paths = path1;
- int npaths;
- int i;
-- char *found;
-- char *pfind = strrchr(command, '/');
--/* char dirbuf[MAX_LINELEN]; */
--#define dirbuf (S.exe_n_cwd_tab_completion__dirbuf)
-+ char *pfind;
-+ char *dirbuf = NULL;
-
- npaths = 1;
- path1[0] = (char*)".";
-
-- if (pfind == NULL) {
-- /* no dir, if flags==EXE_ONLY - get paths, else "." */
-- npaths = path_parse(&paths, type);
-+ pfind = strrchr(command, '/');
-+ if (!pfind) {
-+ if (type == FIND_EXE_ONLY)
|
[-]
[+]
|
Deleted |
busybox-1.17.2-udhcp-services.patch
^
|
@@ -1,24 +0,0 @@
---- networking/udhcp/common.c.orig 2010-08-23 02:44:35.000000000 +0200
-+++ networking/udhcp/common.c 2010-09-29 12:15:08.514367497 +0200
-@@ -49,6 +49,10 @@
- { OPTION_STRING , 0x43 }, /* DHCP_BOOT_FILE */
- //TODO: not a string, but a set of LASCII strings:
- // { OPTION_STRING , 0x4D }, /* DHCP_USER_CLASS */
-+ { OPTION_IP | OPTION_LIST , 0x45 }, /* DHCP_SMTP_SERVER */
-+ { OPTION_IP | OPTION_LIST , 0x46 }, /* DHCP_POP3_SERVER */
-+ { OPTION_IP | OPTION_LIST , 0x4a }, /* DHCP_IRC_SERVER */
-+ { OPTION_IP | OPTION_LIST , 0x48 }, /* DHCP_WWW_SERVER */
- #if ENABLE_FEATURE_UDHCP_RFC3397
- { OPTION_DNS_STRING | OPTION_LIST , 0x77 }, /* DHCP_DOMAIN_SEARCH */
- { OPTION_SIP_SERVERS , 0x78 }, /* DHCP_SIP_SERVERS */
-@@ -105,6 +109,10 @@
- "tftp" "\0" /* DHCP_TFTP_SERVER_NAME */
- "bootfile" "\0" /* DHCP_BOOT_FILE */
- // "userclass" "\0" /* DHCP_USER_CLASS */
-+ "smtpsrv" "\0" /* DHCP_SMTP_SERVER */
-+ "pop3srv" "\0" /* DHCP_POP3_SERVER */
-+ "ircsrv" "\0" /* DHCP_IRC_SERVER */
-+ "wwwsrv" "\0" /* DHCP_WWW_SERVER */
- #if ENABLE_FEATURE_UDHCP_RFC3397
- "search" "\0" /* DHCP_DOMAIN_SEARCH */
- // doesn't work in udhcpd.conf since OPTION_SIP_SERVERS
|
[-]
[+]
|
Added |
busybox-1.18.3-buildsys.patch
^
|
@@ -0,0 +1,10 @@
+--- busybox-1.18.3/Config.in
++++ busybox-1.18.3-buildsys/Config.in
+@@ -126,7 +126,6 @@ config FEATURE_INSTALLER
+ config INSTALL_NO_USR
+ bool "Don't use /usr"
+ default n
+- depends on FEATURE_INSTALLER
+ help
+ Disable use of /usr. busybox --install and "make install"
+ will install applets only to /bin and /sbin,
|
[-]
[+]
|
Added |
busybox-1.18.3-modutils24.patch
^
|
@@ -0,0 +1,36 @@
+--- busybox-1.18.3/modutils/modutils-24.c
++++ busybox-1.18.3-modutils24/modutils/modutils-24.c
+@@ -2474,6 +2474,7 @@ new_process_module_arguments(struct obj_
+ n = 0;
+ p = val;
+ while (*p != 0) {
++ char sv_ch;
+ char *endp;
+
+ if (++n > max)
+@@ -2482,14 +2483,17 @@ new_process_module_arguments(struct obj_
+ switch (*pinfo) {
+ case 's':
+ len = strcspn(p, ",");
++ sv_ch = p[len];
+ p[len] = 0;
+ obj_string_patch(f, sym->secidx,
+ loc - contents, p);
+ loc += tgt_sizeof_char_p;
+ p += len;
++ *p = sv_ch;
+ break;
+ case 'c':
+ len = strcspn(p, ",");
++ sv_ch = p[len];
+ p[len] = 0;
+ if (len >= charssize)
+ bb_error_msg_and_die("string too long for %s (max %ld)", param,
+@@ -2497,6 +2501,7 @@ new_process_module_arguments(struct obj_
+ strcpy((char *) loc, p);
+ loc += charssize;
+ p += len;
++ *p = sv_ch;
+ break;
+ case 'b':
+ *loc++ = strtoul(p, &endp, 0);
|
[-]
[+]
|
Added |
busybox-1.18.3-udhcp-services.patch
^
|
@@ -0,0 +1,24 @@
+--- networking/udhcp/common.c.orig 2010-08-23 02:44:35.000000000 +0200
++++ networking/udhcp/common.c 2010-09-29 12:15:08.514367497 +0200
+@@ -49,6 +49,10 @@
+ { OPTION_STRING , 0x43 }, /* DHCP_BOOT_FILE */
+ //TODO: not a string, but a set of LASCII strings:
+ // { OPTION_STRING , 0x4D }, /* DHCP_USER_CLASS */
++ { OPTION_IP | OPTION_LIST , 0x45 }, /* DHCP_SMTP_SERVER */
++ { OPTION_IP | OPTION_LIST , 0x46 }, /* DHCP_POP3_SERVER */
++ { OPTION_IP | OPTION_LIST , 0x4a }, /* DHCP_IRC_SERVER */
++ { OPTION_IP | OPTION_LIST , 0x48 }, /* DHCP_WWW_SERVER */
+ #if ENABLE_FEATURE_UDHCP_RFC3397
+ { OPTION_DNS_STRING | OPTION_LIST , 0x77 }, /* DHCP_DOMAIN_SEARCH */
+ { OPTION_SIP_SERVERS , 0x78 }, /* DHCP_SIP_SERVERS */
+@@ -105,6 +109,10 @@
+ "tftp" "\0" /* DHCP_TFTP_SERVER_NAME */
+ "bootfile" "\0" /* DHCP_BOOT_FILE */
+ // "userclass" "\0" /* DHCP_USER_CLASS */
++ "smtpsrv" "\0" /* DHCP_SMTP_SERVER */
++ "pop3srv" "\0" /* DHCP_POP3_SERVER */
++ "ircsrv" "\0" /* DHCP_IRC_SERVER */
++ "wwwsrv" "\0" /* DHCP_WWW_SERVER */
+ #if ENABLE_FEATURE_UDHCP_RFC3397
+ "search" "\0" /* DHCP_DOMAIN_SEARCH */
+ // doesn't work in udhcpd.conf since OPTION_SIP_SERVERS
|
[-]
[+]
|
Added |
busybox-1.18.3-wget.patch
^
|
@@ -0,0 +1,128 @@
+--- busybox-1.18.3/networking/wget.c
++++ busybox-1.18.3-wget/networking/wget.c
+@@ -446,7 +446,7 @@ static FILE* prepare_ftp_session(FILE **
+
+ static void NOINLINE retrieve_file_data(FILE *dfp, int output_fd)
+ {
+- char buf[512];
++ char buf[4*1024]; /* made bigger to speed up local xfers */
+ #if ENABLE_FEATURE_WGET_STATUSBAR || ENABLE_FEATURE_WGET_TIMEOUT
+ # if ENABLE_FEATURE_WGET_TIMEOUT
+ unsigned second_cnt;
+@@ -455,7 +455,6 @@ static void NOINLINE retrieve_file_data(
+
+ polldata.fd = fileno(dfp);
+ polldata.events = POLLIN | POLLPRI;
+- ndelay_on(polldata.fd);
+ #endif
+ progress_meter(PROGRESS_START);
+
+@@ -464,6 +463,10 @@ static void NOINLINE retrieve_file_data(
+
+ /* Loops only if chunked */
+ while (1) {
++
++#if ENABLE_FEATURE_WGET_STATUSBAR || ENABLE_FEATURE_WGET_TIMEOUT
++ ndelay_on(polldata.fd);
++#endif
+ while (1) {
+ int n;
+ unsigned rdsz;
+@@ -493,22 +496,46 @@ static void NOINLINE retrieve_file_data(
+ progress_meter(PROGRESS_BUMP);
+ }
+ #endif
++ /* fread internally uses read loop, which in our case
++ * is usually exited when we get EAGAIN.
++ * In this case, libc sets error marker on the stream.
++ * Need to clear it before next fread to avoid possible
++ * rare false positive ferror below. Rare because usually
++ * fread gets more than zero bytes, and we don't fall
++ * into if (n <= 0) ...
++ */
++ clearerr(dfp);
++ errno = 0;
+ n = safe_fread(buf, rdsz, dfp);
++ /* man fread:
++ * If error occurs, or EOF is reached, the return value
++ * is a short item count (or zero).
++ * fread does not distinguish between EOF and error.
++ */
+ if (n <= 0) {
+- if (ferror(dfp)) {
+- /* perror will not work: ferror doesn't set errno */
+- bb_error_msg_and_die(bb_msg_read_error);
+- }
+- break;
++#if ENABLE_FEATURE_WGET_STATUSBAR || ENABLE_FEATURE_WGET_TIMEOUT
++ if (errno == EAGAIN) /* poll lied, there is no data? */
++ continue; /* yes */
++#endif
++ if (ferror(dfp))
++ bb_perror_msg_and_die(bb_msg_read_error);
++ break; /* EOF, not error */
+ }
++
+ xwrite(output_fd, buf, n);
+ #if ENABLE_FEATURE_WGET_STATUSBAR
+ G.transferred += n;
+ progress_meter(PROGRESS_BUMP);
+ #endif
+- if (G.got_clen)
++ if (G.got_clen) {
+ G.content_len -= n;
++ if (G.content_len == 0)
++ break;
++ }
+ }
++#if ENABLE_FEATURE_WGET_STATUSBAR || ENABLE_FEATURE_WGET_TIMEOUT
++ ndelay_off(polldata.fd);
++#endif
+
+ if (!G.chunked)
+ break;
+@@ -706,6 +733,11 @@ int wget_main(int argc UNUSED_PARAM, cha
+ fprintf(sfp, "Host: %s\r\nUser-Agent: %s\r\n",
+ target.host, user_agent);
+
++ /* Ask server to close the connection as soon as we are done
++ * (IOW: we do not intend to send more requests)
++ */
++ fprintf(sfp, "Connection: close\r\n");
++
+ #if ENABLE_FEATURE_WGET_AUTHENTICATION
+ if (target.user) {
+ fprintf(sfp, "Proxy-Authorization: Basic %s\r\n"+6,
+@@ -719,22 +751,25 @@ int wget_main(int argc UNUSED_PARAM, cha
+
+ if (G.beg_range)
+ fprintf(sfp, "Range: bytes=%"OFF_FMT"u-\r\n", G.beg_range);
++
+ #if ENABLE_FEATURE_WGET_LONG_OPTIONS
+ if (extra_headers)
+ fputs(extra_headers, sfp);
+
+ if (opt & WGET_OPT_POST_DATA) {
+ char *estr = URL_escape(post_data);
+- fprintf(sfp, "Content-Type: application/x-www-form-urlencoded\r\n");
+- fprintf(sfp, "Content-Length: %u\r\n" "\r\n" "%s",
+- (int) strlen(estr), estr);
+- /*fprintf(sfp, "Connection: Keep-Alive\r\n\r\n");*/
+- /*fprintf(sfp, "%s\r\n", estr);*/
++ fprintf(sfp,
++ "Content-Type: application/x-www-form-urlencoded\r\n"
++ "Content-Length: %u\r\n"
++ "\r\n"
++ "%s",
++ (int) strlen(estr), estr
++ );
+ free(estr);
+ } else
+ #endif
+- { /* If "Connection:" is needed, document why */
+- fprintf(sfp, /* "Connection: close\r\n" */ "\r\n");
++ {
++ fprintf(sfp, "\r\n");
+ }
+
+ fflush(sfp);
|
|
Changed |
busybox-1.18.3.tar.bz2
^
|