summaryrefslogtreecommitdiff
path: root/networking/wget.c
diff options
context:
space:
mode:
authorEric Andersen <andersen@codepoet.org>2001-01-20 20:07:00 +0000
committerEric Andersen <andersen@codepoet.org>2001-01-20 20:07:00 +0000
commit370fb08e799111e40456990bb088819cbd80b492 (patch)
tree790bc25d64b7de8b7130f363bb6322232c6dd625 /networking/wget.c
parent609268030562d76f14fa385afaa831f042109c48 (diff)
downloadbusybox-w32-370fb08e799111e40456990bb088819cbd80b492.tar.gz
busybox-w32-370fb08e799111e40456990bb088819cbd80b492.tar.bz2
busybox-w32-370fb08e799111e40456990bb088819cbd80b492.zip
Clarify the statusbar config option so it states which applet it applies to.
Diffstat (limited to 'networking/wget.c')
-rw-r--r--networking/wget.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/networking/wget.c b/networking/wget.c
index 77577d9b4..0745a9e99 100644
--- a/networking/wget.c
+++ b/networking/wget.c
@@ -40,7 +40,7 @@ void progressmeter(int flag);
40 40
41/* Globals (can be accessed from signal handlers */ 41/* Globals (can be accessed from signal handlers */
42static off_t filesize = 0; /* content-length of the file */ 42static off_t filesize = 0; /* content-length of the file */
43#ifdef BB_FEATURE_STATUSBAR 43#ifdef BB_FEATURE_WGET_STATUSBAR
44static char *curfile; /* Name of current file being transferred. */ 44static char *curfile; /* Name of current file being transferred. */
45static struct timeval start; /* Time a transfer started. */ 45static struct timeval start; /* Time a transfer started. */
46volatile unsigned long statbytes; /* Number of bytes transferred so far. */ 46volatile unsigned long statbytes; /* Number of bytes transferred so far. */
@@ -113,18 +113,18 @@ int wget_main(int argc, char **argv)
113 /* Guess an output filename */ 113 /* Guess an output filename */
114 if (!fname_out) { 114 if (!fname_out) {
115 fname_out = 115 fname_out =
116#ifdef BB_FEATURE_STATUSBAR 116#ifdef BB_FEATURE_WGET_STATUSBAR
117 curfile = 117 curfile =
118#endif 118#endif
119 get_last_path_component(uri_path); 119 get_last_path_component(uri_path);
120 if (fname_out==NULL || strlen(fname_out)<1) { 120 if (fname_out==NULL || strlen(fname_out)<1) {
121 fname_out = 121 fname_out =
122#ifdef BB_FEATURE_STATUSBAR 122#ifdef BB_FEATURE_WGET_STATUSBAR
123 curfile = 123 curfile =
124#endif 124#endif
125 "index.html"; 125 "index.html";
126 } 126 }
127#ifdef BB_FEATURE_STATUSBAR 127#ifdef BB_FEATURE_WGET_STATUSBAR
128 } else { 128 } else {
129 curfile=argv[optind]; 129 curfile=argv[optind];
130#endif 130#endif
@@ -217,14 +217,14 @@ int wget_main(int argc, char **argv)
217 /* 217 /*
218 * Retrieve HTTP body. 218 * Retrieve HTTP body.
219 */ 219 */
220#ifdef BB_FEATURE_STATUSBAR 220#ifdef BB_FEATURE_WGET_STATUSBAR
221 statbytes=0; 221 statbytes=0;
222 if (quiet_flag==FALSE) 222 if (quiet_flag==FALSE)
223 progressmeter(-1); 223 progressmeter(-1);
224#endif 224#endif
225 while (filesize > 0 && (n = fread(buf, 1, sizeof(buf), sfp)) > 0) { 225 while (filesize > 0 && (n = fread(buf, 1, sizeof(buf), sfp)) > 0) {
226 fwrite(buf, 1, n, output); 226 fwrite(buf, 1, n, output);
227#ifdef BB_FEATURE_STATUSBAR 227#ifdef BB_FEATURE_WGET_STATUSBAR
228 statbytes+=n; 228 statbytes+=n;
229 if (quiet_flag==FALSE) 229 if (quiet_flag==FALSE)
230 progressmeter(1); 230 progressmeter(1);
@@ -341,7 +341,7 @@ char *gethdr(char *buf, size_t bufsiz, FILE *fp, int *istrunc)
341 return hdrval; 341 return hdrval;
342} 342}
343 343
344#ifdef BB_FEATURE_STATUSBAR 344#ifdef BB_FEATURE_WGET_STATUSBAR
345/* Stuff below is from BSD rcp util.c, as added to openshh. 345/* Stuff below is from BSD rcp util.c, as added to openshh.
346 * Original copyright notice is retained at the end of this file. 346 * Original copyright notice is retained at the end of this file.
347 * 347 *
@@ -476,7 +476,7 @@ progressmeter(int flag)
476} 476}
477#endif 477#endif
478 478
479/* Original copyright notice which applies to the BB_FEATURE_STATUSBAR stuff, 479/* Original copyright notice which applies to the BB_FEATURE_WGET_STATUSBAR stuff,
480 * much of which was blatently stolen from openssh. */ 480 * much of which was blatently stolen from openssh. */
481 481
482/*- 482/*-
@@ -511,7 +511,7 @@ progressmeter(int flag)
511 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 511 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
512 * SUCH DAMAGE. 512 * SUCH DAMAGE.
513 * 513 *
514 * $Id: wget.c,v 1.15 2001/01/03 16:15:15 kraai Exp $ 514 * $Id: wget.c,v 1.16 2001/01/20 20:07:00 andersen Exp $
515 */ 515 */
516 516
517 517