1 2003-10-07 Hrvoje Niksic <hniksic@xemacs.org>
3 * cookies.c (struct cookie): Remove unused backpointer to cookie
6 2003-10-07 Hrvoje Niksic <hniksic@xemacs.org>
8 * cmpt.c (memmove): Comment out, since it's no longer used.
10 * cookies.c (cookie_jar_generate_cookie_header): Allocate room for
12 (find_chains_of_host): Assume that the caller has allocated DEST
13 to be sufficiently large to take all the data.
14 (eliminate_dups): Run through the array and eliminate dups on the
15 fly instead of using memmove.
16 (cookie_jar_process_set_cookie): Free cookie->domain before
19 2003-10-05 Gisle Vanem <giva@bgnett.no>
21 * mswindows.c (set_sleep_mode): Fix type of
22 _SetThreadExecutionState.
24 2003-10-05 Hrvoje Niksic <hniksic@xemacs.org>
26 * utils.c (file_size): Return -1 if fopen() returns NULL. Prior
27 to this patch, wget --post-file=nosuchfile dumped core.
29 2003-10-04 Gisle Vanem <giva@bgnett.no>
31 * mswindows.c (run_with_timeout): Use WaitForSingleObject to wait
32 for thread termination.
34 2003-10-04 Hrvoje Niksic <hniksic@xemacs.org>
36 * log.c: Use `...' in function definitions; ansi2knr will convert
37 them to va_dcl. This allowed removal of the ugly VA_START_1 and
40 2003-10-03 Gisle Vanem <giva@bgnett.no>
42 * connect.c: And don't include them here.
44 * mswindows.h: Include winsock headers here.
46 2003-10-03 Hrvoje Niksic <hniksic@xemacs.org>
48 * html-parse.c (convert_and_copy): Move variable declarations
51 2003-10-02 Gisle Vanem <giva@bgnett.no>
53 * mswindows.c (run_with_timeout): For Windows: Run the 'fun' in a
54 thread via a helper function. Continually query the thread's
55 exit-code until finished or timed out.
57 2003-10-02 Hrvoje Niksic <hniksic@xemacs.org>
59 * wget.h (XMALLOC_ARRAY): Removed.
60 (ALLOCA_ARRAY): Ditto.
62 * html-parse.c: Renamed alloca_p to resized.
63 (GROW_ARRAY): Renamed DO_REALLOC_FROM_ALLOCA to GROW_ARRAY and
64 returned it to html-parse.c, since nothing else was using it.
66 2003-10-02 Hrvoje Niksic <hniksic@xemacs.org>
68 * retr.c (retrieve_url): Initialize DUMMY storage for DT. Caught
71 2003-10-02 Hrvoje Niksic <hniksic@xemacs.org>
73 * html-parse.c (convert_and_copy): Handle numeric entities in
75 (convert_and_copy): Copy the contents directly to the pool without
76 a stack-allocated intermediary.
78 2003-10-02 Hrvoje Niksic <hniksic@xemacs.org>
80 * utils.c (alarm_set): New function; use either setitimer or alarm
82 (alarm_cancel): New function; cancel the alarm set up by
84 (run_with_timeout): Use them.
86 2003-10-01 Hrvoje Niksic <hniksic@xemacs.org>
88 * url.c (url_parse): Don't leak memory when a reencoded URL turns
91 * url.c (parse_errors): Mark error messages for translation.
92 (url_error): Translate error messages returned to the caller.
94 2003-10-01 Hrvoje Niksic <hniksic@xemacs.org>
96 * ftp.c (ftp_loop_internal): Initialize TMRATE to NULL to shut up
99 2003-09-26 Gisle Vanem <giva@bgnett.no>
101 * src/mswindows.c: Added ws_percenttitle() showing progress in the
102 window titlebar. Called from retr.c. Secured ws_mypath().
104 * windows/config.h.ms: alloca() prototype not needed. Removed
105 "#undef ENABLE_NLS"; should be in Makefile IMHO. Moved
106 WGET_USE_STDARG from mswindows.h to config.ms.h because of #ifdef
107 in log.c. (MSVC's vararg.h and stdarg.h are incompatible).
109 2003-09-29 Aaron Hawley <Aaron.Hawley@uvm.edu>
111 * ftp.c (getftp): --spider option should now work with FTP
113 (ftp_loop_internal): quiet reports and calculations of downloads
114 when --spider option set, nor try deleting when --delete-after
116 (ftp_loop): --spider will skip HTML-ification of .listing file.
118 2003-09-26 Gisle Vanem <giva@bgnett.no>
120 * mswindows.c (read_registry): Removed.
121 (set_sleep_mode): New function.
122 (windows_main_junk): Call it.
124 2003-09-26 Gisle Vanem <giva@bgnett.no>
126 * mswindows.c (read_registry): Fix invocation of registry
129 * mswindows.c (read_registry): Condition definitions of sleep and
130 usleep with not HAVE_SLEEP and HAVE_USLEEP respectively. Define
131 HAVE_SLEEP and HAVE_USLEEP under __DMC__.
133 2003-09-24 Hrvoje Niksic <hniksic@xemacs.org>
135 * url.c (url_escape_1): Revert unintentional change to lowercase
137 (url_escape_dir): Document that this function depends on the
138 output of url_escape_1.
140 2003-09-23 Hrvoje Niksic <hniksic@xemacs.org>
142 * progress.c (create_image): Print the current ETA if we're done
144 (create_image): Change '-' display char to '+' in the progress bar.
146 * Makefile.in (clean): Remove .libs.
148 2003-09-23 Hrvoje Niksic <hniksic@xemacs.org>
150 * cookies.c (struct cookie): New flag domain_exact.
151 (update_cookie_field): Skip leading dot in domain.
152 (find_matching_chains): Match numeric addresses exactly; don't
153 needlessly copy HOST to the stack.
154 (matching_cookie): Added argument HOST. If cookie->domain_exact
155 is set, check that HOST is equal to cookie->domain.
156 (cookie_jar_load): Only use TAB as delimiter. Document the
157 meaning of DOMAIN-FLAG. Skip leading dot in domain.
158 (cookie_jar_load): Don't ignore DOMAIN-FLAG -- instead, set
159 domain_exact to true if DOMAIN-FLAG is false.
160 (save_cookies_mapper): If domain_exact is false, prepend the
161 domain with dot, like Mozilla does.
163 2003-09-22 Hrvoje Niksic <hniksic@xemacs.org>
165 * progress.c (create_image): Print the initial part of the
166 download with '-' characters, analogous to how dot progress prints
167 the initial part with ','.
169 * hash.c (ptrhash): New function.
171 (hash_table_new): Default to identity hash table.
173 2003-09-22 Hrvoje Niksic <hniksic@xemacs.org>
175 * safe-ctype.h (_sch_test): The cast of BIT to unsigned char was
176 broken -- _sch_istable bitmasks are 16-bit, not 8-bit! Cast BIT
177 to unsigned short instead.
179 2003-09-22 Hrvoje Niksic <hniksic@xemacs.org>
181 * url.c (path_simplify): Instead of calls to memmove, handle "./"
182 and "../" by advancing pointers.
184 2003-09-22 Hrvoje Niksic <hniksic@xemacs.org>
186 * retr.c (getproxy): Moved from url.c.
188 * convert.c: Split off link conversion from url.c into separate
189 file. Also included the book-keeping stuff from recur.c.
191 2003-09-21 Hrvoje Niksic <hniksic@xemacs.org>
193 * init.c: Improved documentation of functions.
194 (cmd_boolean): Attempt to make code that tries to avoid calling
195 strcmp for "speed" a bit more readable.
197 * init.c (simple_atof): Report error on encountering non-digit,
199 (simple_atoi): Replacement for myatoi(), calling interface
200 compatible with simple_atof. Updated myatoi's callers.
202 2003-09-21 Bertrand Demiddelaer <bert@b3rt.org>
204 * url.c (path_simplify): Would read two bytes past the end of the
205 string in the "./" case.
207 2003-09-21 Matthew J. Mellon <mellon@tymenet.com>
209 * http.c (gethttp): Recognize content-type "application/xhtml+xml"
210 as what Wget considers "text/html".
212 2003-09-21 Hrvoje Niksic <hniksic@xemacs.org>
214 * connect.c (connect_with_timeout): Made timeout type double.
216 * options.h (struct options): New members read_timeout,
217 dns_timeout, and connect_timeout.
220 2003-09-21 Hrvoje Niksic <hniksic@xemacs.org>
222 * init.c (simple_atof): New function.
224 (cmd_bytes): Accept things like "1.5k" and such. Use simple_atof
227 * retr.c (limit_bandwidth): Adjust each sleep by the error of the
230 2003-09-21 Hrvoje Niksic <hniksic@xemacs.org>
232 * main.c (main): Use setoptval() for setting the options. Use
233 run_command for `-e'.
235 * init.c (parse_line): Rewritten to return COMIND right away.
236 Changed linkage to static.
237 (run_wgetrc): Use the available comind when calling setval, so it
238 doesn't have to be computed twice.
239 (setval_internal): New function, runs the command's action without
241 (setoptval): New function, does what setval used to do, but exits
243 (run_command): New function.
245 2003-09-21 Hrvoje Niksic <hniksic@xemacs.org>
247 * connect.c (select_fd): Change MAXTIME's type to double. Handle
250 * retr.c (sleep_between_retrievals): In the random-wait case, use
251 random_float() to wait between 0 and 2*opt.wait seconds.
253 * utils.c (run_with_timeout): Accept `double' timeouts. Correctly
254 handle timeout values in (0, 1) range.
255 (random_float): New function.
257 * options.h (struct options): Change the types of wait, waitretry,
258 and timeout to double.
260 * init.c (cmd_time): Accept floating point time.
262 2003-09-20 Hrvoje Niksic <hniksic@xemacs.org>
264 * retr.c (get_contents): Cosmetic fixes.
266 2003-09-20 Hrvoje Niksic <hniksic@xemacs.org>
268 * url.c (uri_merge): Get rid of uri_merge_1.
269 (uri_merge): Merge "foo//", "bar" as "foo//bar", not "foo///bar",
270 i.e. don't add an extra slash merely because BASE ends with two
272 (parse_credentials): Renamed from parse_uname. Rewrittern in
273 standard [beg, end) calling style.
274 (url_skip_credentials): Renamed from url_skip_uname. Made static.
275 (url_skip_credentials): Include # and ; as terminators. Old code
276 would mistakenly consider "http://foo.com#hniksic@iskon.hr" to
278 (url_skip_scheme): Removed because it was unused.
279 (url_has_scheme): Require "scheme" to be at least one char long.
281 2003-09-19 Hrvoje Niksic <hniksic@xemacs.org>
283 * url.c (url_file_name): Expect NULL dir_prefix.
285 * init.c (cmd_file): Use a macro to prevent multiple #ifdef
287 (defaults): Set dir_prefix to NULL by default.
289 2003-09-19 Hrvoje Niksic <hniksic@xemacs.org>
291 * safe-ctype.h (_sch_test): Cast BIT to unsigned char, like latest
294 2003-09-19 Hrvoje Niksic <hniksic@xemacs.org>
296 * wget.h (BOUNDED_TO_ALLOCA): Evaluate PLACE only once.
297 (ARRAY_SIZE): Renamed to countof. All callers updated.
299 2003-09-19 Hrvoje Niksic <hniksic@xemacs.org>
301 * main.c (main): New option --strict-comments.
303 * html-parse.c (find_comment_end): New function: simple BM search
305 (map_html_tags): Use it if looking at a comment and not in strict
308 2003-09-17 Aurelien Marchand <artaxerxes@users.sf.net>
310 * ftp.h: Added OS400 system in enum
311 * ftp-basic.c: recognize OS400 systems
312 * ftp.c: don't prepend the CWD if talking to OS400, since it
313 breaks the change in library
315 2003-09-18 Hrvoje Niksic <hniksic@xemacs.org>
317 * retr.c (get_contents): Pass the correct argument to ssl_iread.
319 2003-09-18 Hrvoje Niksic <hniksic@xemacs.org>
321 * safe-ctype.h: Don't #define ctype.h macros to errors because
322 that loses when someone #include's ctype.h after safe-ctype.h.
324 2003-09-17 Hrvoje Niksic <hniksic@xemacs.org>
326 * url.c: Undef U, W, C after use.
328 2003-09-17 Hrvoje Niksic <hniksic@xemacs.org>
330 * init.c (cmd_spec_restrict_file_names): Allow the OS setting to
331 be augmented by ",nocontrol" which means don't escape the control
332 characters, but otherwise keep OS settings.
334 * url.c (file_unsafe_char): Deleted.
335 (append_uri_pathel): Query filechr_table directly.
336 (filechr_table): Separated Unix, Windows, and control-unsafe
339 2003-09-17 Hrvoje Niksic <hniksic@xemacs.org>
341 * url.c (url_escape_1): New function.
342 (url_escape): Use it.
343 (sync_path): Handle pathological cases where u->file and u->dir
344 contain really strange characters.
348 2003-09-16 Hrvoje Niksic <hniksic@xemacs.org>
350 * url.c (url_file_name): Don't reallocate FNAME if the file
351 doesn't exist, as is usually the case.
353 * utils.c (unique_name): New flag allow_passthrough.
355 2003-09-16 Hrvoje Niksic <hniksic@xemacs.org>
357 * utils.c (wtimer_sys_diff): Convert the time difference to signed
358 __int64, then to double. This works around MS VC++ 6 which can't
359 convert unsigned __int64 to double directly.
361 2003-09-16 Hrvoje Niksic <hniksic@xemacs.org>
363 * Makefile.in (clean): Also remove the core.<number> files
364 produced by recent Linux systems.
366 2003-09-16 Hrvoje Niksic <hniksic@xemacs.org>
368 * http.c (post_file): Don't pad the file if it's not large
369 enough. Bail out instead.
371 2003-09-15 Hrvoje Niksic <hniksic@xemacs.org>
373 * retr.c (get_contents): Reduce the buffer size to the amount of
374 data that may pass through for one second. This prevents long
375 sleeps when limiting bandwidth.
377 * connect.c (connect_to_one): Reduce the socket's RCVBUF when
378 bandwidth limitation to small values is requested.
380 2003-09-15 Hrvoje Niksic <hniksic@xemacs.org>
382 * progress.c (update_speed_ring): Moved the speed ring update to a
383 separate function and documented it better.
385 * progress.c: Use `double' for most timers to support granularity
388 2003-09-15 Hrvoje Niksic <hniksic@xemacs.org>
390 * wget.h (XDIGIT_TO_XCHAR): Implement as index into a literal
392 (XDIGIT_TO_xchar): Ditto.
394 2003-09-15 Hrvoje Niksic <hniksic@xemacs.org>
396 * utils.c: Change the type of timer-related functions from long to
397 double, for better precision. On machines supporting gettimeofday
398 the timers now work with granularity of less than one millisecond.
400 2003-09-15 Hrvoje Niksic <hniksic@xemacs.org>
402 * cookies.c (parse_set_cookies): Fixed the parser to handle more
404 (test_cookies): New function, contains a test suite for
407 2003-09-15 Hrvoje Niksic <hniksic@xemacs.org>
409 * url.c (strpbrk_or_eos): Implement as a macro under Gcc.
411 2003-09-15 Hrvoje Niksic <hniksic@xemacs.org>
413 * cookies.c (parse_set_cookies): Allow trailing space in
414 set-cookies header. Also, allow any amount of whitespace, not
415 only one character. Allow empty set-cookies header without
418 2003-09-14 Hrvoje Niksic <hniksic@xemacs.org>
420 * url.c (append_uri_pathel): Use opt.restrict_file_names when
421 calling file_unsafe_char.
423 * init.c: New command restrict_file_names.
425 * main.c (main): New option --restrict-file-names[=windows,unix].
427 * url.c (url_file_name): Renamed from url_filename.
428 (url_file_name): Add directory and hostdir prefix here, not in
430 (append_dir_structure): New function, does part of the work that
431 used to be in mkstruct. Iterates over path elements in u->path,
432 calling append_uri_pathel on each one to append it to the file
434 (append_uri_pathel): URL-unescape a path element and reencode it
435 with a different set of rules, more appropriate for handling of
437 (file_unsafe_char): New function, uses a lookup table to decide
438 whether a character should be escaped for use in file name.
439 (append_string): New utility function.
440 (append_char): Ditto.
441 (file_unsafe_char): New argument restrict_for_windows, decide
442 whether Windows file names should be escaped in run-time.
444 * connect.c: Include <stdlib.h> to get prototype for abort().
446 2003-09-14 Hrvoje Niksic <hniksic@xemacs.org>
448 * utils.c (wtimer_sys_set): Extracted the code that sets the
450 (wtimer_reset): Call it.
451 (wtimer_sys_diff): Extracted the code that calculates the
452 difference between two system times here.
453 (wtimer_elapsed): Call it.
454 (wtimer_elapsed): Don't return a value smaller than the previous
455 one, which could previously happen when system time is set back.
456 Instead, reset start time to current time and note the elapsed
457 offset for future calculations. The returned times are now
458 guaranteed to be monotonically nondecreasing.
460 2003-09-10 Hrvoje Niksic <hniksic@xemacs.org>
462 * host.c (lookup_host): Print the result of the DNS lookup.
464 2003-09-10 Hrvoje Niksic <hniksic@xemacs.org>
466 * init.c (cmd_boolean): Accept yes/no along with on/off.
467 (cmd_lockable_boolean): Ditto.
469 2003-09-10 Hrvoje Niksic <hniksic@xemacs.org>
471 * init.c: New command dns_cache.
473 * main.c (main): New option --dns-cache[=off].
475 2003-09-09 Hrvoje Niksic <hniksic@xemacs.org>
477 * config.h.in: Initialize HAVE_GETADDRINFO and ENABLE_IPV6.
479 * all: Use #ifdef ENABLE_IPV6 instead of the older INET6. Use
480 HAVE_GETADDRINFO for getaddrinfo-related stuff.
482 2003-09-09 Hrvoje Niksic <hniksic@xemacs.org>
484 * url.c (url_parse): Return an error if the URL contains a [...]
485 IPv6 numeric address and we don't support IPv6.
487 2003-09-05 Hrvoje Niksic <hniksic@xemacs.org>
489 * url.c (is_valid_ipv6_address): Modified to not require
490 zero-terminated strings.
491 (is_valid_ipv4_address): Ditto.
493 2003-09-05 Mauro Tortonesi <mauro@deepspace6.net>
495 src/url.c: added RFC 2732 compliance for URL parsing. The
496 functions is_*_address valid are a modified version of
497 glibc 2.3.2 inet_pton's code.
499 2003-09-03 Ahmon Dancy <dancy@dancysoft.com>
501 * main.c init.c options.h: Added --retry-connrefused option so
502 that Connection Refused failures are treated as non-fatal (when
503 trying to retrieve from busy servers).
505 * wget.h: New CONNECT_ERROR macro for encapsulating this
508 * ftp.c http.c : Use CONNECT_ERROR macro in places where
509 ECONNREFUSED was checked.
511 2003-01-11 Ian Abbott <abbotti@mev.co.uk>
513 * ftp.c (ftp_retrieve_glob): Reject insecure filenames as determined
514 by calling new function has_insecure_name_p. This is based on a
517 * fnmatch.c (has_insecure_name_p): New function: returns non-zero
518 if filename starts with `/' or contains `../' and is therefore
521 * fnmatch.h: Declare has_insecure_name_p().
523 2002-08-03 Hrvoje Niksic <hniksic@xemacs.org>
525 * init.c (cmd_file): Allocate RESULT correctly.
527 2002-07-24 Hrvoje Niksic <hniksic@xemacs.org>
529 * recur.c (retrieve_tree): Check whether downloaded_html_set is
530 non-NULL before using it.
532 2002-05-27 Hrvoje Niksic <hniksic@arsdigita.com>
534 * html-parse.c (NAME_CHAR_P): Allow almost any character here.
536 2002-05-24 Hrvoje Niksic <hniksic@arsdigita.com>
538 * progress.c (bar_set_params): Fall back to dot progress if the
539 terminal type is "emacs".
541 2002-05-20 Hrvoje Niksic <hniksic@arsdigita.com>
543 * log.c: Don't #undef WGET_USE_STDARG.
545 2002-05-16 Hrvoje Niksic <hniksic@arsdigita.com>
547 * hash.c (prime_size): Store the offset of the prime number in the
548 prime table. When searching, start with the given offset.
549 (hash_table_new): Pass the pointer to ht->prime_offset to
551 (grow_hash_table): Ditto.
552 (prime_size): Make 13 the first prime to make empty hash tables
555 2002-05-16 Ian Abbott <abbotti@mev.co.uk>
557 * recur.c (download_child_p): Minor optimization to avoid an
558 unnecessary additional call to schemes_are_similar_p function.
560 2002-05-16 Ian Abbott <abbotti@mev.co.uk>
562 * url.c (schemes_are_similar_p): New function to test enumerated
563 scheme codes for similarity.
567 * recur.c (download_child_p): Use it to compare schemes. This
568 also fixes a bug that allows hosts to be spanned (without the
569 -H option) when the parent scheme is https and the child's is
572 2002-05-14 Bill Richardson <bill@riverstonenet.com>
574 * ftp.c (getftp): Don't ftruncate stdout.
576 * http.c (gethttp): Don't ftruncate stdout.
578 2002-05-09 Ian Abbott <abbotti@mev.co.uk>
580 * cmpt.c (strptime_internal): Synched with glibc-2.1.3.
582 (get_alt_number): Ditto.
583 (__isleap): New function-like macro used by strptime.
584 (day_of_the_week): New function used by strptime.
585 (day_of_the_year): Ditto.
586 (__mon_yday): Now shared by mktime and strptime implementations.
588 2002-05-08 Hrvoje Niksic <hniksic@arsdigita.com>
590 * cookies.c (check_domain_match): Use match_tail in case
593 * utils.c (match_tail): Allow the caller to specify case
596 * cookies.c (store_cookie): When expiry_time is 0, print it as
597 undefined, not indefinite.
599 2002-05-07 Ian Abbott <abbotti@mev.co.uk>
601 * cookies.c (cookie_jar_process_set_cookie): Do not store
604 2002-04-21 Hrvoje Niksic <hniksic@arsdigita.com>
606 * cookies.c (check_domain_match): Allow cookies to be set for
607 subdomains of unknown top-level domains under some circumstances.
609 2002-04-21 Thomas Lussnig <thomas.lussnig@bewegungsmelder.de>
612 - allow checking of server cert
613 - allow defining client cert type
614 - allow limit of ssl protocol
615 - check more return values
616 - added debug message on break
618 2002-04-21 Hrvoje Niksic <hniksic@arsdigita.com>
620 * recur.c (download_child_p): Revert order of items in check
621 number 6 for clarity.
623 2002-04-20 Hrvoje Niksic <hniksic@arsdigita.com>
629 * http.c: Use the new interface.
631 * cookies.c: Provide an OO-style "cookie jar" interface to enable
632 separate cookie jars.
634 * http.c (http_atotm): Declare argument as const.
636 2002-04-20 Hrvoje Niksic <hniksic@arsdigita.com>
638 * cookies.c (cookie_new): Default to PORT_ANY.
639 (find_cookie_chain_exact): Only search by DOMAIN.
640 (find_matching_cookie): Also check that PORT matches.
641 (store_cookie): Only match the domain.
642 (set_cookie_header_cb): When a cookie "fakes" a domain, assume it
643 is valid for that host rather than discarding it completely.
644 (find_matching_chains): Don't search by PORT.
645 (matching_cookie): Also match PORT.
646 (load_cookies): Set the port if specified, otherwise leave it as
648 (save_cookies_mapper): Save the port if specified, otherwise leave
651 2002-04-19 Thomas Lussnig <thomas.lussnig@bewegungsmelder.de>
653 * init.c: The option `egdfile' was not in sort order.
655 2002-04-16 Hrvoje Niksic <hniksic@arsdigita.com>
657 * ftp.c (getftp): Treat directories that begin with <letter>: as
659 (getftp): Strip trailing slashes from con->id before merging it
662 2002-04-16 Hrvoje Niksic <hniksic@arsdigita.com>
664 * http.c (gethttp): If Content-Type is not given, assume
667 2002-04-15 Hrvoje Niksic <hniksic@arsdigita.com>
669 * recur.c (download_child_p): Don't ignore rejection of HTML
670 documents that are themselves leaves of recursion.
672 2002-04-15 Ian Abbott <abbotti@mev.co.uk>
674 Makefile.in: Updated several dependencies for object files to take
675 account of nested include files.
677 2002-04-15 Ian Abbott <abbotti@mev.co.uk>
679 Makefile.in: The target `connect$o' (connect.o) now depends on
682 2002-04-15 Ian Abbott <abbotti@mev.co.uk>
684 * host.c (SET_H_ERRNO): New function-like macro to set `h_errno'.
685 (gethostbyname_with_timeout): Use it.
687 * utils.c: Don't define `SETJMP()', `run_with_timeout_env' or
688 `abort_run_with_timeout()' when `USE_SIGNAL_TIMEOUT' is undefined.
690 2002-04-15 Hrvoje Niksic <hniksic@arsdigita.com>
692 * host.c (getaddrinfo_with_timeout): New function.
693 (gethostbyname_with_timeout): Ditto.
694 (lookup_host): Use them.
696 2002-04-14 Hrvoje Niksic <hniksic@arsdigita.com>
698 * utils.c (number_to_string): Handle the case when n < -INT_MAX.
700 2002-04-14 Hrvoje Niksic <hniksic@arsdigita.com>
702 * init.c (comind): Use a marginally faster implementation of
703 binary search. To quote Martin Buchholz, "a nanosecond saved is a
706 2002-04-14 Hrvoje Niksic <hniksic@arsdigita.com>
708 * main.c (print_help): Document `--post-data' and `--post-file'.
710 2002-04-14 Hrvoje Niksic <hniksic@arsdigita.com>
712 * http.c (gethttp): Ditto.
714 * retr.c (retrieve_url): Initialize variables to appease the
717 * gen_sslfunc.c (ssl_iread): Don't handle EINTR when calling
721 * connect.c (select_fd): Rewrite to handle EINTR. Set errno to
722 ETIMEDOUT in case of timeout.
723 (iread): No need to handle EINTR when calling select_fd.
726 2002-04-14 Hrvoje Niksic <hniksic@arsdigita.com>
728 * retr.c (retrieve_url): Make sure that POST is not honored for
731 * http.c (gethttp): Send the POST data when requested.
732 (post_file): New function.
735 * main.c (main): Ditto.
737 * init.c: Add new options.
739 * options.h (struct options): New options post_data and
742 2002-04-14 Hrvoje Niksic <hniksic@arsdigita.com>
744 * connect.c (connect_with_timeout): Firing SIGALRM can result in
745 connect() exiting with EINTR. Treat EINTR the same as ETIMEDOUT.
747 2002-04-13 Hrvoje Niksic <hniksic@arsdigita.com>
749 * connect.c (connect_with_timeout): Use it.
751 * utils.c (run_with_timeout): New function.
753 2002-04-13 Hrvoje Niksic <hniksic@arsdigita.com>
755 * url.c (getproxy): Accept a struct url argument. This obviates
756 the need for USE_PROXY_P.
758 * retr.c (retrieve_url): Allow proxy to be a non-FTP URL.
760 * ftp.c (getftp): Recognize FWTK-style proxy.
762 2002-04-12 Hrvoje Niksic <hniksic@arsdigita.com>
764 * config.h.in: Only define _VA_LIST when compiled with gcc.
766 2002-04012 Ian Abbott <abbotti@mev.co.uk>
768 * http.c (http_loop): Compensate for MS Windows two-second
769 granularity of file modification time when comparing timestamps.
771 * ftp.c (ftp_retrieve_list): Ditto.
773 2002-04-12 Ian Abbott <abbotti@mev.co.uk>
775 * utils.c (has_html_suffix_p): New function to test filename for
776 common html extensions.
778 * utils.h: Declare it.
780 * http.c (http_loop): Use it instead of previous test.
782 * retr.c (retrieve_url): Ditto.
784 * recur.c (download_child_p): Ditto.
786 2002-04-12 Hrvoje Niksic <hniksic@arsdigita.com>
788 * config.h.in: Define _VA_LIST on Solaris to prevent stdio.h from
790 From Kevin Rodgers <kevinr@ihs.com>.
792 2002-04-12 Ian Abbott <abbotti@mev.co.uk>
794 * Makefile.in: Specify libtool mode explicitly when linking.
796 2002-04-12 Hrvoje Niksic <hniksic@arsdigita.com>
798 * connect.c (connect_with_timeout): New function.
799 (connect_to_one): Use it.
801 * config.h.in: Add stubs for HAVE_SIGSETJMP, HAVE_SIGBLOCK, and
804 2002-04-11 Hrvoje Niksic <hniksic@arsdigita.com>
806 * log.c: Set WGET_USE_STDARG if __STDC__ is defined and stdarg.h
809 2002-04-11 Hrvoje Niksic <hniksic@arsdigita.com>
811 * progress.c (bar_create): If INITIAL is larger than TOTAL, fix
813 (bar_finish): Likewise.
815 2002-04-11 Hrvoje Niksic <hniksic@arsdigita.com>
817 * html-url.c (tag_handle_form): New function. Pick up form
818 actions and mark them for conversion only.
820 2002-04-11 Hrvoje Niksic <hniksic@arsdigita.com>
822 * progress.c (struct progress_implementation): Use PARAMS when
823 declaring the parameters of *create, *update, *finish, and
828 * http.c: Reformat some function definitions so that ansi2knr can
831 * hash.c (struct hash_table): Use the PARAMS macro around
832 parameters in the declaration of hash_function and test_function.
833 (prime_size): Spell 2580823717UL and 3355070839UL as (unsigned
834 long)0x99d43ea5 and (unsigned long)0xc7fa5177 respectively, so
835 that pre-ANSI compilers can read them.
836 (find_mapping): Use PARAMS when declaring EQUALS.
837 (hash_table_put): Ditto.
839 * ftp.h: Wrap the parameters of ftp_index declaration in PARAMS.
841 * cookies.c (cookie_new): Use (unsigned long)0 instead of 0UL,
842 which was unsupported by pre-ANSI compilers.
844 From Nelson H. F. Beebe <beebe@math.utah.edu>, for the most part.
846 2002-04-11 Hrvoje Niksic <hniksic@arsdigita.com>
848 * url.c (url_filename): Use compose_file_name regardless of
849 whether opt.dirstruct is set.
850 (mkstruct): Don't handle the query and the reencoding of DIR; that
851 is done in compose_file_name.
853 2002-04-10 Hrvoje Niksic <hniksic@arsdigita.com>
855 * wget.h: Ditto for extern char *exec_name.
857 * options.h: Don't guard against OPTIONS_DEFINED_HERE -- it is
858 perfectly legal to follow an `extern' with a non-`extern' ones,
859 provided the types match.
861 * main.c: Don't define OPTIONS_DEFINED_HERE.
863 2002-04-10 Hrvoje Niksic <hniksic@arsdigita.com>
865 * progress.c (create_image): Revert to calculating ETA based on
866 average download speed.
867 (create_image): Don't print ETA until the download has been active
868 for at least 3 seconds.
869 (create_image): When ETA is not available, don't print anything.
870 The previous version would print --:--.
872 2002-04-10 Hrvoje Niksic <hniksic@arsdigita.com>
874 * progress.c (bar_update): Keep updating a subinterval until it
875 reaches or exceeds a watermark. That way the measurement will be
876 guaranteed to span a configurable minimum of time. The current
877 default is 3s in 30 100ms intervals.
879 2002-04-09 Hrvoje Niksic <hniksic@arsdigita.com>
881 * progress.c (bar_update): Maintain an array of the time it took
882 to perform previous 30 network reads.
883 (create_image): Calculate the download speed and ETA based on the
884 last 30 reads, not the entire download.
885 (create_image): Make sure that the ETA is not changed more than
888 2002-04-09 Ian Abbott <abbotti@mev.co.uk>
890 * mswindows.c (borland_utime): New function conditionally defined
891 when `HACK_BCC_UTIME_BUG' is defined. A reimplementation of
892 `utime()' as Borland's `utime()' function is broken on Windows 9x
893 systems. (Original patch by Chin-yuan Kuo <sr1111111@yahoo.com.tw>.)
895 2002-04-08 Hrvoje Niksic <hniksic@arsdigita.com>
897 * ftp.c (ftp_loop): Propagate the result of ftp_retrieve_glob.
899 2002-03-26 Ian Abbott <abbotti@mev.co.uk>
901 * Makefile.in: Updated several dependencies for object files.
903 2002-03-20 Ian Abbott <abbotti@mev.co.uk>
905 * mswindows.c: Include "utils.h".
907 2002-03-18 Ian Abbott <abbotti@mev.co.uk>
909 * host.h: Don't include netdb.h on windows.
911 2002-02-19 Hrvoje Niksic <hniksic@arsdigita.com>
913 * recur.c (retrieve_tree): Handle the case when start_url doesn't
916 2002-02-19 Andreas Damm <andreas-sourceforge@radab.org>
918 * wget.h (DO_REALLOC_FROM_ALLOCA): Multiply with sizeof(type) when
919 calling xmalloc and memcpy.
921 2002-02-19 Hrvoje Niksic <hniksic@arsdigita.com>
923 * host.h: Include Unix-specific includes #ifndef WINDOWS.
924 Patch originally provided by Christian Lackas.
926 2002-02-11 Christian Lackas <delta@lackas.net>
928 * recur.c: recurive downloading for https fixed.
930 2002-02-19 Alan Eldridge <alane@geeksrus.net>
932 * host.h: Also include <netinet/in.h> and <sys/socket.h>.
934 * ftp-basic.c: Also include <netinet/in.h>.
936 2002-02-05 Ian Abbott <abbotti@mev.co.uk>
938 * http.c (gethttp): when -c used, mark already fully retrieved
939 file as successfully retrieved.
941 2002-02-19 Hrvoje Niksic <hniksic@arsdigita.com>
943 * url.c (url_parse): Don't treat '?' as query string separator
944 when parsing FTP URLs.
946 2002-02-01 Hrvoje Niksic <hniksic@arsdigita.com>
948 * html-url.c (tag_handle_meta): Don't crash on <meta
949 http-equiv=refresh> where content is missing.
951 2002-01-31 Herold Heiko <Heiko.Herold@previnet.it>
953 * ftp-basic.c, host.c: don't include sys/socket.h, arpa/inet.h,
956 2002-01-30 Hrvoje Niksic <hniksic@arsdigita.com>
958 * retr.c (retrieve_url): Remove redirection cycle detection. This
959 is because some sites legitimately redirect the user back to the
960 same location, e.g. after an authorization check performed by
961 another page. MAX_REDIRECTIONS is still used to prevent infinite
964 2002-01-26 Hrvoje Niksic <hniksic@arsdigita.com>
966 * http.c (gethttp): Wrap host name in square brackets if it
969 2002-01-26 Hrvoje Niksic <hniksic@arsdigita.com>
971 * url.c (url_parse): Allow all hex digits, not only decimal ones,
972 to form an IP address.
974 2002-01-26 Hrvoje Niksic <hniksic@arsdigita.com>
976 * url.c (urlchr_table): Make square braces reserved, so we can
978 (url_parse): Handle host in braces.
979 (url_string): If url->host contains colons, wrap it in braces.
981 2002-01-24 Hrvoje Niksic <hniksic@arsdigita.com>
983 * connect.c (resolve_bind_address): New function.
984 (connect_to_one): Use it.
987 * init.c: Don't resolve bind-address here.
989 * host.c (wget_sockaddr_set_address): Would bug out with ADDR == NULL.
991 2002-01-24 Hrvoje Niksic <hniksic@arsdigita.com>
993 * host.c (lookup_host): Use sizeof(ip4_address) to calculate the
995 (address_list_new): Use map_ipv4_to_ip.
996 (wget_sockaddr_set_address): Convert ADDR to IPv4 before using it
999 2002-01-24 Hrvoje Niksic <hniksic@arsdigita.com>
1001 * source: Integrated IPv6 support.
1002 Written by Thomas Lussnig <thomas.lussnig@bewegungsmelder.de>.
1004 2002-01-15 Ian Abbott <abbotti@mev.co.uk>
1006 * init.c (cmd_file): Change `\' to `/' for Windows (yes, really!)
1007 (cmd_directory): New function. Like cmd_file(), but strips
1008 trailing directory separators.
1009 (commands): Change action for "dirprefix" from `cmd_file' to
1012 * utils.c (make_directory): Allow intermediate `mkdir' calls to
1013 fail, as not all path components that do not exist should be
1014 directory components, especially under Windows.
1016 2002-01-17 Hrvoje Niksic <hniksic@arsdigita.com>
1018 * netrc.c (parse_netrc): Skip leading whitespace before testing
1019 whether the line is empty. Empty lines still contain the line
1022 2002-01-15 Hrvoje Niksic <hniksic@arsdigita.com>
1024 * gen_sslfunc.c (ssl_iread): Call select on the file descriptor
1025 only if no data is pending in SSL buffers.
1026 From tony@bluetail.com.
1028 2002-01-14 Hrvoje Niksic <hniksic@arsdigita.com>
1030 * headers.c (header_get): Strip trailing whitespace from the
1033 2002-01-14 Hrvoje Niksic <hniksic@arsdigita.com>
1035 * url.c (parse_uname): URL-decode *USER and *PASSWD.
1037 2002-01-07 Ian Abbott <abbotti@mev.co.uk>
1039 * url.c (uri_merge_1): Deal with "net path" relative URL (one that
1042 2002-01-14 Hrvoje Niksic <hniksic@arsdigita.com>
1044 * http.c (gethttp): Invalidate SOCK if get_contents encountered an
1047 2001-12-24 Hrvoje Niksic <hniksic@arsdigita.com>
1049 * version.c: Wget 1.8.1 is released.
1051 2001-12-19 Hrvoje Niksic <hniksic@arsdigita.com>
1053 * version.c: Wget 1.8.1-pre3 is released.
1055 2001-12-19 Hrvoje Niksic <hniksic@arsdigita.com>
1057 * recur.c (retrieve_tree): Enqueue the canonical representation of
1058 start_url, so that the test against dl_url_file_map works.
1060 2001-12-19 Hrvoje Niksic <hniksic@arsdigita.com>
1062 * log.c (logputs): Check for requested verbosity before printing
1065 2001-12-19 Hrvoje Niksic <hniksic@arsdigita.com>
1067 * html-url.c (tag_handle_link): Treat the "shortcut icon" link as
1070 2001-12-18 Hrvoje Niksic <hniksic@arsdigita.com>
1072 * recur.c (retrieve_tree): Make a copy of file obtained from
1073 dl_url_file_map because the code calls xfree(file) later.
1075 2001-12-18 Hrvoje Niksic <hniksic@arsdigita.com>
1077 * recur.c (register_html): Maintain a hash table of HTML files
1078 along with the list. Disallow duplicates.
1079 (retrieve_tree): Use downloaded_html_set to check whether the file
1080 found in dl_url_file_map is an HTML file, and descend into it if
1082 (convert_all_links): Don't guard against duplicates in
1083 downloaded_html_list, since they are no longer possible.
1085 2001-12-18 Ian Abbott <abbotti@mev.co.uk>
1087 * recur.c (retrieve_tree): Pass on referring URL when retrieving
1090 2001-12-17 Hrvoje Niksic <hniksic@arsdigita.com>
1092 * version.c: Wget 1.8.1-pre2 is released.
1094 2001-12-17 Hrvoje Niksic <hniksic@arsdigita.com>
1096 * retr.c (sleep_between_retrievals): Simplify indentation.
1098 2001-12-17 Hrvoje Niksic <hniksic@arsdigita.com>
1100 * gen_sslfunc.c (ssl_init_prng): Use random_number to get a byte
1101 of "randomness" at a time.
1102 (ssl_init_prng): Don't seed the PRNG; random_number will do that.
1104 * retr.c (sleep_between_retrievals): Use it. Make sure that the
1105 random amount averages in opt.wait.
1106 (sleep_between_retrievals): Don't seed the PRNG; random_number
1109 * utils.c (random_number): New function.
1111 2001-12-14 Hrvoje Niksic <hniksic@arsdigita.com>
1113 * url.c (path_simplify): Move here from utils.c, and make static.
1115 2001-12-13 Hrvoje Niksic <hniksic@arsdigita.com>
1117 * init.c (wgetrc_file_name): Print correct message when loading
1118 getenv("WGETRC") fails.
1120 2001-12-13 Hrvoje Niksic <hniksic@arsdigita.com>
1122 * recur.c (register_download): Don't abort when one URL references
1123 two different files.
1125 2001-12-13 Hrvoje Niksic <hniksic@arsdigita.com>
1127 * http.c (gethttp): Check for conn->scheme, not u->scheme, before
1130 2001-12-13 Hrvoje Niksic <hniksic@arsdigita.com>
1132 * version.c: Wget 1.8.1-pre1 is released.
1134 2001-12-13 Hrvoje Niksic <hniksic@arsdigita.com>
1136 * res.c (matches): Fix broken URL in the docstring.
1138 2001-12-13 Hrvoje Niksic <hniksic@arsdigita.com>
1140 * html-url.c (tag_url_attributes): Mark <embed href=...> as
1143 2001-12-12 Hrvoje Niksic <hniksic@arsdigita.com>
1145 * url.c (get_urls_file): Cosmetic changes.
1147 2001-12-12 Hrvoje Niksic <hniksic@arsdigita.com>
1149 * html-url.c (append_one_url): Resurrect warning when unable to
1150 resolve a relative link.
1152 2001-12-12 Hrvoje Niksic <hniksic@arsdigita.com>
1154 * html-url.c (collect_tags_mapper): Break into several functions.
1155 (tag_url_attributes): Collect <embed href=...>.
1157 2001-12-11 Hrvoje Niksic <hniksic@arsdigita.com>
1159 * host.c: New type ipv4_address. Use it consistently instead of
1160 `unsigned char[4]' and `unsigned char *'.
1161 (pretty_print_address): Accept a `const void *', to require even
1164 2001-12-11 Hrvoje Niksic <hniksic@arsdigita.com>
1166 * ftp-ls.c (ftp_parse_vms_ls): Fix obvious memory leaks.
1168 2001-12-10 Hrvoje Niksic <hniksic@arsdigita.com>
1170 * main.c (main): Initialize progress after fork_to_background, so
1171 that it knows when to use dots.
1173 * mswindows.c (ws_hangup): Call log_request_redirect_output.
1175 * utils.c (fork_to_background): Print the PID of the child
1178 * log.c (log_request_redirect_output): Set a flag that output
1179 redirection has been requested. Doing anything else in a signal
1181 (check_redirect_output): New function: check whether redirection
1182 has been requested and, if so, call redirect_output().
1183 (logputs): Call check_redirect_output.
1185 (debug_logprintf): Ditto.
1186 (redirect_output): Print clearer messages.
1188 * main.c (redirect_output_signal): Don't call
1189 redirect_output_signal directly. Instead, call
1190 log_request_redirect_output.
1192 * utils.c (memfatal): Ditto.
1194 * progress.c (display_image): Use it.
1196 * log.c (log_set_save_context): New function: allow the caller to
1197 turn off saving log context lines.
1199 2001-12-10 Hrvoje Niksic <hniksic@arsdigita.com>
1201 * host.c (address_list_set_faulty): Uncomment a sanity check.
1203 2001-12-10 Hrvoje Niksic <hniksic@arsdigita.com>
1205 * utils.c (long_to_string): Return a pointer after where the
1207 (long_to_string): Rename to number_to_string.
1209 2001-12-10 Hrvoje Niksic <hniksic@arsdigita.com>
1211 * utils.c (path_simplify): Correctly handle the unlikely case that
1212 b starts out as path + 1.
1214 2001-12-10 Hrvoje Niksic <hniksic@arsdigita.com>
1216 * utils.c (path_simplify): Rewrite, with better comments, and
1217 without the use of strcpy to move overlapping blocks.
1219 2001-12-09 Hrvoje Niksic <hniksic@arsdigita.com>
1221 * init.c (cmd_spec_progress): Resurrect. Check whether VAL is a
1222 valid progress type before setting it.
1224 2001-12-09 Hrvoje Niksic <hniksic@arsdigita.com>
1226 * main.c (main): Remove stray debugging message.
1228 2001-12-09 Hrvoje Niksic <hniksic@arsdigita.com>
1230 * progress.c (create_image): Fix ETA padding when hours are prined.
1232 2001-12-09 Hrvoje Niksic <hniksic@arsdigita.com>
1234 * version.c: Wget 1.8 is released.
1236 2001-12-09 Hrvoje Niksic <hniksic@arsdigita.com>
1238 * url.c (reencode_string): Declare static.
1240 * res.c (registered_specs): Declare static.
1242 * progress.c (current_impl_locked): Declare static.
1244 * log.c (flush_log_p): Declare static.
1245 (needs_flushing): Ditto.
1247 * http.c (digest_authentication_encode): Declare static.
1249 * html-url.c (init_interesting): Declare static.
1251 * host.c (host_name_addresses_map): Declare static.
1253 * cookies.c (find_matching_chains): Declare static.
1255 * ftp-ls.c (ftp_parse_vms_ls): Warn about the memory leak
1258 * utils.c (path_simplify): Remove unused variable STUB_CHAR.
1260 * host.c (address_list_set_faulty): Document that INDEX is
1263 * url.c (rewrite_shorthand_url): Remove unused variable PATH.
1265 2001-12-08 Hrvoje Niksic <hniksic@arsdigita.com>
1267 * version.c: Wget 1.8-pre2 is released.
1269 2001-12-06 Hrvoje Niksic <hniksic@arsdigita.com>
1271 * progress.c (progress_handle_sigwinch): Set up the signal again.
1273 * utils.c: Include <sys/termios.h>, where Solaris defines
1276 * progress.c (bar_create): Don't use the last column on the screen.
1277 (create_image): Pad ETA to constant size. Pad SIZE to nine digits
1278 only until it exceeded them.
1280 2001-12-06 Hrvoje Niksic <hniksic@arsdigita.com>
1282 * version.c: Wget 1.8-pre1 is released.
1284 2001-12-06 Hrvoje Niksic <hniksic@arsdigita.com>
1286 * progress.c (progress_create): Make sure that, when the output is
1287 redirected, the progress implementation gets changed to the
1289 (bar_set_params): Set current_impl_locked to 1 when "force" is
1291 (progress_create): Don't change the progress implementation if
1292 current_impl_locked is non-zero.
1294 * main.c (redirect_output_signal): Call
1295 progress_schedule_redirect.
1297 * progress.c (progress_schedule_redirect): New function.
1299 2001-12-06 Hrvoje Niksic <hniksic@arsdigita.com>
1301 * log.c (logvprintf): Restructure to allow being called multiple
1303 (logprintf): Call logvprintf in a loop.
1304 (debug_logprintf): Ditto.
1306 2001-12-06 Hrvoje Niksic <hniksic@arsdigita.com>
1308 * gen_sslfunc.c (ssl_init_prng): Allow the user to disable EGD by
1309 setting egd_file it to empty string.
1311 * main.c (main): Change the option name from --sslegdsock to
1314 2001-12-06 Hrvoje Niksic <hniksic@arsdigita.com>
1316 * gen_sslfunc.c (ssl_init_prng): Make the printed message
1319 2001-12-06 Hrvoje Niksic <hniksic@arsdigita.com>
1321 * url.c (scheme_disable): New function.
1323 * main.c (main): Call ssl_init_prng from here rather than from
1324 init_ssl, so that it has a chance to disable support for https
1325 before a URL has been resolved.
1327 * gen_sslfunc.c (ssl_init_prng): Seed with rand() if all else
1329 (ssl_init_prng): Disable support for https if seeding the PRNG
1332 2001-12-06 Hrvoje Niksic <hniksic@arsdigita.com>
1334 * utils.c (read_whole_line): Handle lines beginning with \0.
1336 2001-12-05 Hrvoje Niksic <hniksic@arsdigita.com>
1338 * recur.c (convert_all_links): Guard against duplicates in
1339 downloaded_html_files.
1340 (register_download): Don't invalidate similar-looking URLs.
1341 (match_except_index): New function.
1343 2001-12-05 Hrvoje Niksic <hniksic@arsdigita.com>
1345 * utils.c (path_simplify): Document with test cases.
1347 2001-12-04 Hrvoje Niksic <hniksic@arsdigita.com>
1349 * gen_sslfunc.c: Ditto.
1351 * rbuf.c: Include <string.h>.
1353 2001-12-04 Hrvoje Niksic <hniksic@arsdigita.com>
1355 * recur.c (retrieve_tree): Check whether the URL was already
1356 downloaded before downloading it again.
1357 (descend_child_p): Renamed to download_child_p.
1358 (register_download): When one URL is downloaded to a file already
1359 "owned" by another URL, delete all references that map any URL to
1361 (register_delete_file): New function.
1362 (retrieve_tree): Use it after deleting a file.
1364 * url.c (url_parse): Re-canonicalize the URL also if the path is
1365 empty, so that e.g. "http://www.server.com" ->
1366 "http://www.server.com/".
1367 (lowercase_str): Use ISUPPER instead of !ISLOWER.
1369 * retr.c (retrieve_url): Use the canonical URL form when calling
1370 register_download().
1372 2001-12-04 Ian Abbott <abbotti@mev.co.uk>
1374 * snprintf.c (dopr): Use `unsigned int' as the second argument to
1375 va_arg when casting to `unsigned short' is intended.
1377 2001-12-04 Herold Heiko <Heiko.Herold@previnet.it>
1379 * gen_sslfunc.c: on windows provide ssl crypto random
1380 initialization through RAND_screen(); could possibly
1381 be not enough for strong ssl communication (see the
1382 relevant manual page from the openssl package).
1384 2001-12-04 Hrvoje Niksic <hniksic@arsdigita.com>
1386 * url.c (local_quote_string): Reenable quoting of question marks,
1387 but only when `--html-extension' is used.
1389 2001-12-03 Hrvoje Niksic <hniksic@arsdigita.com>
1391 * version.c: Wget 1.8-beta3 is released.
1393 2001-12-03 Hrvoje Niksic <hniksic@arsdigita.com>
1395 * snprintf.c (dopr): Cast the result of va_arg to short int and
1396 short unsigned int where these types are expected to be used.
1398 2001-12-03 Hrvoje Niksic <hniksic@arsdigita.com>
1400 * snprintf.c (dopr): Replace `short int' and `unsigned short int'
1401 with `int' when using it as the second argument to `va_arg'.
1403 2001-12-03 Hrvoje Niksic <hniksic@arsdigita.com>
1405 * host.c (address_list_new_one): New function.
1406 (lookup_host): Use it.
1408 2001-12-03 Andre Majorel <amajorel@teaser.fr>
1410 * host.c (lookup_host): Don't initialize TMPSTORE directly because
1413 2001-12-03 Hrvoje Niksic <hniksic@arsdigita.com>
1415 * ftp-basic.c (ftp_port): Don't return HOSTERR if we fail getting
1420 * http.c: No need to declare h_errno.
1422 * host.c: Declare h_errno.
1424 2001-12-02 Hrvoje Niksic <hniksic@arsdigita.com>
1426 * utils.c (file_merge): If BASE doesn't contain a slash, just
1427 return a copy of FILE.
1429 2001-12-02 Hrvoje Niksic <hniksic@arsdigita.com>
1431 * version.c: Wget 1.8-beta2 is released.
1433 2001-12-01 Hrvoje Niksic <hniksic@arsdigita.com>
1435 * ftp.c (getftp): When PWD fails, assume "/".
1437 * ftp-basic.c (ftp_syst): Fix indentation.
1439 2001-12-01 Hrvoje Niksic <hniksic@arsdigita.com>
1441 * url.c (get_urls_file): If opt.base_href is specified, merge each
1444 2001-12-01 Hrvoje Niksic <hniksic@arsdigita.com>
1446 * main.c (print_help): Don't document the removed `-nh'.
1448 2001-12-01 Hrvoje Niksic <hniksic@arsdigita.com>
1450 * url.c (url_full_path): Document better.
1452 * http.c (gethttp): Use the full path when creating digest
1455 2001-12-01 Hrvoje Niksic <hniksic@arsdigita.com>
1457 * cookies.c (path_matches): Return 0 if PREFIX doesn't begin with
1460 2001-12-01 Hrvoje Niksic <hniksic@arsdigita.com>
1462 * cookies.c (path_matches): FULL_PATH doesn't begin with '/', but
1465 2001-12-01 Hrvoje Niksic <hniksic@arsdigita.com>
1467 * cookies.c (check_domain_match): Reimplement to match Netscape's
1468 "preliminary specification" for cookies.
1470 2001-12-01 Hrvoje Niksic <hniksic@arsdigita.com>
1472 * url.c (replace_attr_refresh_hack): New function.
1473 (convert_links): Call replace_attr_refresh_hack for Refresh
1474 links. It will add the "TMOUT; URL=" junk before the link.
1476 * html-url.c (collect_tags_mapper): Set ID to the ID of the
1477 "content" attribute, not "http-equiv".
1478 (collect_tags_mapper): Don't use OFFSET to hack the raw_* values;
1479 instead, store the information that this entry belongs to a
1482 2001-12-01 Hrvoje Niksic <hniksic@arsdigita.com>
1484 * version.c: Wget 1.8-beta1 is released.
1486 2001-12-01 Hrvoje Niksic <hniksic@arsdigita.com>
1488 * recur.c (retrieve_tree): Allow -p retrievals to exceed maximum
1489 depth by more than one.
1491 2001-11-30 Hrvoje Niksic <hniksic@arsdigita.com>
1493 * retr.c (retrieve_url): Don't allow more than 20 redirections.
1495 2001-11-30 Hrvoje Niksic <hniksic@arsdigita.com>
1497 * recur.c (retrieve_tree): Skip the non-inline entries when
1498 enqueuing the children of a leaf HTML node in -p mode.
1499 (descend_url_p): Ignore opt.no_parent when in -p mode and UPOS is
1502 * html-url.c (get_urls_html): Don't accept dash_p_leaf_HTML.
1503 (collect_tags_mapper): When an entry is "inline", mark it as such.
1505 * recur.c (descend_url_p): Fix test when checking for
1506 acceptance/rejection rules.
1508 2001-10-31 Daniel BODEA <dali@dali-designs.com>
1510 * netrc.c (search_netrc): When slack_default is 0, still look for
1511 an account with matching password, just not the "default account".
1512 HTTP Authorization using .netrc should now work as expected.
1514 2001-11-30 T. Bharath <TBharath@responsenetworks.com>
1516 * http.c (persistent_available_p): Call SHUTDOWN_SSL if
1517 test_socket_open fails.
1519 2001-11-30 Hrvoje Niksic <hniksic@arsdigita.com>
1521 * progress.c (display_image): Just print one CR to reset the
1524 2001-11-30 Christian Fraenkel <c.fraenkel@gmx.net>
1526 * init.c: New command `ssl_egd_sock'.
1528 * main.c (main): New option `--sslegdsock'.
1530 * gen_sslfunc.c (ssl_init_prng): Seed the RNG using EGD.
1532 2001-11-29 Hrvoje Niksic <hniksic@arsdigita.com>
1534 * cmpt.c (memmove): Include a simple memmove implementation.
1536 2001-11-29 Hrvoje Niksic <hniksic@arsdigita.com>
1538 * headers: Guard against header files being included twice.
1540 2001-11-29 Hrvoje Niksic <hniksic@arsdigita.com>
1542 * gen-md5.c: Use unsigned char * as the buffer argument to
1545 2001-11-29 Hrvoje Niksic <hniksic@arsdigita.com>
1547 * connect.h: Declare select_fd.
1549 2001-11-29 Hrvoje Niksic <hniksic@arsdigita.com>
1551 * recur.c (descend_url_p): When resolving no_parent, compare with
1552 start_url, not parent url. Otherwise link from /a/b/ to /a/c/
1553 wouldn't be followed, although the download started from /a/.
1555 2001-01-23 Herold Heiko <Heiko.Herold@previnet.it>
1557 * config.h.ms, mswindows.h: defined HAVE_ISATTY, use _isatty for
1558 MS VC; somebody with Borland compiler please check and provide
1561 * cmpt.c: provided a usleep emulation.
1563 2001-11-29 Hrvoje Niksic <hniksic@arsdigita.com>
1565 * host.c (address_list_new): Initialize al->faulty.
1567 2001-11-29 Hrvoje Niksic <hniksic@arsdigita.com>
1569 * http.c (http_process_range): Accept the broken output of
1570 "JavaWebServer/1.1.1".
1572 2001-11-28 Hrvoje Niksic <hniksic@arsdigita.com>
1574 * progress.c (dot_set_params): If PARAMS is unspecified, use
1575 dot_style, if available.
1579 * main.c (main): Resurect --dot-style.
1581 * progress.c (dot_finish): Print the quantity if we're left at the
1584 2001-11-27 Hrvoje Niksic <hniksic@arsdigita.com>
1586 * cmpt.c (random): Removed.
1588 * retr.c (sleep_between_retrievals): Use the more portable rand()
1589 instead of random().
1591 2001-11-27 Ian Abbott <abbotti@mev.co.uk>
1593 * retr.c (retrieve_from_file): Initialize `new_file' to NULL to
1596 2001-11-27 Hrvoje Niksic <hniksic@arsdigita.com>
1598 * connect.c (connect_to_many): Use address_list_set_faulty to
1599 prevent the faulty address from being reused.
1601 * host.c (address_list_set_faulty): New function.
1602 (address_list_get_bounds): New function, instead of
1605 2001-11-27 Hrvoje Niksic <hniksic@arsdigita.com>
1607 * url.c (convert_links): Don't translate %d-%d.
1609 * main.c (print_help): Remove stray HAVE_RANDOM code.
1611 2001-11-27 Hrvoje Niksic <hniksic@arsdigita.com>
1613 * ftp.c (getftp): Improve output after sending PASV. Don't
1614 attempt to "look up" the IP address we already know; call
1615 connect_to_one directly.
1617 2001-11-27 Hrvoje Niksic <hniksic@arsdigita.com>
1619 * progress.c: Change the default progress implementation to "bar".
1621 2001-11-27 Hrvoje Niksic <hniksic@arsdigita.com>
1623 * progress.c (bar_create): Print two newlines.
1625 2001-11-27 Hrvoje Niksic <hniksic@arsdigita.com>
1627 * cmpt.c (random): New function, a simple-minded replacement for
1628 random() on systems that don't have it.
1630 2001-11-26 Hrvoje Niksic <hniksic@arsdigita.com>
1632 * config.h.in: Put a HAVE_USLEEP stub.
1634 * cmpt.c (usleep): Replacement implementation of usleep using
1637 * init.c: New option init_rate.
1639 * main.c (main): New option --limit-rate.
1641 * retr.c (limit_bandwidth): New function.
1642 (get_contents): Call it to limit the bandwidth used when
1645 * progress.c (dot_update): Would print the wrong download speed on
1646 rows other than the first one when the download was continued.
1647 (dot_finish): Ditto.
1649 2001-11-26 Ian Abbott <abbotti@mev.co.uk>
1651 * http.c (gethttp): fix undeclared variable 'err' when compiled
1654 2001-11-26 Hrvoje Niksic <hniksic@arsdigita.com>
1656 * progress.c: Don't allocate new timers; use the timing data
1657 propagated from the caller.
1659 * retr.c (get_contents): Allocate and use a timer.
1661 2001-11-26 Hrvoje Niksic <hniksic@arsdigita.com>
1663 * http.c (last_host_ip): Made into an address_list.
1664 (invalidate_persistent): Release pc_last_host_ip.
1665 (register_persistent): Use lookup_host.
1666 (persistent_available_p): Check for equality of hosts using
1667 address_list_match_all. Call address_list_release.
1668 (http_cleanup): New function.
1670 * ftp.c (getftp): Use lookup_host and connect_to_many.
1672 * http.c (gethttp): Use lookup_host and connect_to_many.
1674 * connect.c (make_connection): Removed.
1675 (connect_to_one): New function.
1676 (connect_to_many): Ditto.
1677 (set_connection_host_name): Ditto.
1679 * host.c (lookup_host): New function; new return type.
1680 (address_list_new): New function.
1681 (address_list_count): Ditto.
1682 (address_list_copy_one): Ditto.
1683 (address_list_delete): Ditto.
1684 (address_list_release): Ditto.
1685 (pretty_print_address): Ditto.
1687 2001-11-26 Hrvoje Niksic <hniksic@arsdigita.com>
1689 * recur.c (retrieve_tree): In case of followed redirection,
1690 blacklist the pre-redirection URL.
1692 2001-11-26 Hrvoje Niksic <hniksic@arsdigita.com>
1694 * recur.c (descend_redirect_p): New function.
1695 (retrieve_tree): Make sure redirections are not blindly followed.
1697 2001-11-04 Alan Eldridge <alane@geeksrus.net>
1699 * config.h.in: added HAVE_RANDOM.
1701 * options.h: added random_wait to struct options.
1703 * main.c (print_help [HAVE_RANDOM], main): added arg parsing, help
1706 * retr.c (sleep_between_retrievals) [HAVE_RANDOM]: added
1707 implementation of random wait times.
1709 * init.c (commands): added "randomwait" keyword.
1711 2001-11-25 Hrvoje Niksic <hniksic@arsdigita.com>
1713 * recur.c (descend_url_p): Be more conservative with blacklisting
1715 (convert_all_links): Print how many files have been converted, and
1718 * progress.c (create_image): Place the number of downloaded bytes
1719 right after the progress bar.
1721 * utils.c (suffix): Return a pointer into the string.
1723 2001-11-25 Hrvoje Niksic <hniksic@arsdigita.com>
1725 * url.c (convert_links): Handle CO_NULLIFY_BASE.
1727 * recur.c (retrieve_tree): Ignore download-ignorable children.
1728 (convert_all_links): Specify CO_NULLIFY_BASE when link_base_p.
1730 * html-url.c (handle_link): Return the newly created urlpos.
1731 (collect_tags_mapper): When dealing with BASE, store the base
1732 reference and mark it as download-ignorable.
1734 2001-11-25 Hrvoje Niksic <hniksic@arsdigita.com>
1736 * url.c (convert_links): Attempt to quote '?' as "%3F" when
1737 linking to local files. Given up on the attempt, as it breaks
1740 2001-11-25 Hrvoje Niksic <hniksic@arsdigita.com>
1742 * main.c (private_initialize): Removed.
1743 (main): Don't call private_initialize.
1745 * http.c: Call lookup_host.
1747 * host.c (host_init): Removed.
1748 (add_host_to_cache): Initialize host_name_address_map here, on
1750 (ngethostbyname): Commented out.
1752 * connect.c (make_connection): Remove dead code; use lookup_host.
1754 * host.c (store_hostaddress): Renamed to lookup_host and reversed
1756 Removed host_address_name_map and host_slave_master_map.
1758 2001-11-25 Hrvoje Niksic <hniksic@arsdigita.com>
1760 * progress.c (dot_create): Align the "[ skipping ... ]" string
1763 * retr.c (rate): Split into two functions: calc_rate and
1766 * progress.c (create_image): Draw a dummy progress bar even when
1767 total size is unknown.
1768 (display_image): Place the text cursor at the end of the "image".
1770 2001-11-25 Hrvoje Niksic <hniksic@arsdigita.com>
1772 * url.c (reencode_string): Use unsigned char, not char --
1773 otherwise the hex digits come out wrong for 8-bit chars such as
1775 (lowercase_str): New function.
1776 (url_parse): Canonicalize u->url if needed.
1777 (get_urls_file): Parse each URL, and return only the valid ones.
1778 (free_urlpos): Call url_free.
1779 (mkstruct): Add :port if the port is non-standard.
1780 (mkstruct): Append the query string to the file name, if any.
1781 (urlpath_length): Use strpbrk_or_eos.
1782 (uri_merge_1): Handle the cases where LINK is an empty string,
1783 where LINK consists only of query, and where LINK consists only of
1785 (convert_links): Count and report both kinds of conversion.
1786 (downloaded_file): Use a hash table, not a list.
1787 (downloaded_files_free): Free the hash table.
1789 * retr.c (retrieve_from_file): Ditto.
1791 * main.c (main): Call either retrieve_url or retrieve_tree
1792 for each URL, not both.
1794 * retr.c (register_all_redirections): New function.
1795 (register_redirections_mapper): Ditto.
1796 (retrieve_url): Register the redirections.
1797 (retrieve_url): Make the string "Error parsing proxy ..."
1800 * res.c (add_path): Strip leading slash from robots.txt paths so
1801 that the path representations are "compatible".
1802 (free_specs): Free each individual path, too.
1803 (res_cleanup): New function.
1804 (cleanup_hash_table_mapper): Ditto.
1806 * recur.c (url_queue_new): New function.
1807 (url_queue_delete): Ditto.
1808 (url_enqueue): Ditto.
1809 (url_dequeue): Ditto.
1810 (retrieve_tree): New function, replacement for recursive_retrieve.
1811 (descend_url_p): New function.
1812 (register_redirection): New function.
1814 * progress.c (create_image): Cosmetic changes.
1816 * init.c (cleanup): Do all those complex cleanups only if
1817 DEBUG_MALLOC is defined.
1819 * main.c: Removed --simple-check and the corresponding
1820 simple_host_check in init.c.
1822 * html-url.c (handle_link): Parse the URL here, and propagate the
1823 parsed URL to the caller, who would otherwise have to parse it
1826 * host.c (xstrdup_lower): Moved to utils.c.
1827 (realhost): Removed.
1830 2001-11-24 Hrvoje Niksic <hniksic@arsdigita.com>
1832 * utils.c (path_simplify): Preserver the (non-)existence of
1833 leading slash. Return non-zero if changes were made.
1835 2001-11-24 Hrvoje Niksic <hniksic@arsdigita.com>
1837 * progress.c (bar_update): Don't modify bp->total_length if it is
1840 2001-11-24 Hrvoje Niksic <hniksic@arsdigita.com>
1842 * retr.c (retrieve_url): When the redirection URL doesn't parse,
1843 print the correct error message rather than "UNKNOWN".
1845 2001-11-24 Hrvoje Niksic <hniksic@arsdigita.com>
1847 * progress.c (bar_finish): If the timer didn't record any time
1848 since the download beginning, fake 1ms.
1850 2001-11-24 Hrvoje Niksic <hniksic@arsdigita.com>
1852 * recur.c (recursive_retrieve): Fix typo.
1854 2001-11-23 Hrvoje Niksic <hniksic@arsdigita.com>
1856 * progress.c (create_image): Don't translate "%ld ".
1858 2001-11-23 Hrvoje Niksic <hniksic@arsdigita.com>
1860 * progress.c (bar_set_params): Allow the user to force the use of
1863 2001-11-23 Lemble Gregory <gregory.lemble@st.com>
1865 * gen_sslfunc.c (ssl_init_prng): New function; seed the SSL RNG.
1867 2001-11-23 Hrvoje Niksic <hniksic@arsdigita.com>
1869 * progress.c: Renamed dp_* functions to dot_* for greater clarity
1870 and consistency with bar_*.
1871 (print_download_speed): Get rid of the unneeded '@' character.
1872 (create_image): Fix download rate geometry.
1874 * progress.c (print_elapsed): Remove spurious space.
1875 (print_elapsed): Renamed to print_download_speed, since that's
1878 2001-11-23 Hrvoje Niksic <hniksic@arsdigita.com>
1880 * progress.c (bar_update): If the downloaded amount becomes larger
1881 than the expected amount, adjust the expected amount accordingly.
1883 2001-11-23 Hrvoje Niksic <hniksic@arsdigita.com>
1885 * utils.c (determine_screen_width): New function.
1887 * main.c (main): New option `--progress=TYPE'.
1888 (main): Implement compatibility with the old option `--dot-style'.
1890 * init.c: Removed cmd_spec_dotstyle -- that logic is now in
1892 (cmd_spec_progress): New function.
1894 * retr.c (get_contents): Use the progress_* functions instead of
1895 the old show_progress().
1896 (show_progress): Removed.
1897 (rate): Print "xxxx.xx K/s" instead of "KB/s". Ditto for MB/s,
1900 * progress.c (set_progress_implementation): New function.
1901 (valid_progress_implementation_p): Ditto.
1902 (progress_create): Ditto.
1903 (progress_update): Ditto.
1904 (progress_finish): Ditto.
1908 (dp_set_params): Ditto.
1909 (print_elapsed): Ditto.
1911 2001-11-22 Hrvoje Niksic <hniksic@arsdigita.com>
1913 * retr.c (show_progress): Use it.
1915 * log.c (log_set_flush): New function.
1917 2001-11-22 Hrvoje Niksic <hniksic@arsdigita.com>
1919 * utils.c (path_simplify): Don't remove trailing slashes.
1921 * ftp.c (ftp_get_listing): Use it.
1923 * utils.c (file_merge): New function.
1925 * url.c (opt_url): Removed.
1927 * recur.c (recursive_retrieve): Inline "opt_url" logic.
1929 * main.c (main): Use xfree(), not free().
1931 * url.c (rewrite_url_maybe): Renamed to rewrite_shorthand_url.
1933 * ftp.c (ccon): Move `ccon' typedef here, since it's only used
1936 * config.h.in: Include a stub for HAVE_STRPBRK.
1938 * cmpt.c (strpbrk): Include a replacement for systems without
1941 * ftp.c: Use url_set_dir and url_set_file when modifying the URL.
1943 * url.c (url_set_dir): New function.
1944 (url_set_file): Ditto.
1946 * ftp-basic.c (ftp_process_type): Process FTP type here; the URL
1947 parser makes the URL "params" available, so we can do that in this
1952 * ftp.c: Ditto; pass the local file information in `ccon'.
1954 * http.c: Get rid of the ugly kludge that had URL being replaced
1955 with the proxy URL when proxy retrieval was requested. Use a
1956 separate parameter to http_loop and gethttp for the proxy URL.
1958 * http.c: Changed to reflect the fact that local file, proxy, and
1959 referer information are no longer stored in struct url. The local
1960 file information is passed in `struct hstat' now.
1962 * url.c: Reworked URL parsing to be more regular. Reencode the
1963 URL using reencode_string.
1964 Removed non-URL-related information from struct url. This
1965 includes fields `proxy', `local', and `referer'.
1967 2001-11-22 Jochen Hein <jochen@jochen.org>
1969 * main.c (main): Split the copyright notice for easier
1972 2001-08-21 Dave Turner <dct25@hermes.cam.ac.uk>
1974 * ftp-basic.c (ftp_size): New function to send non-standard SIZE
1975 command to server to request file size.
1976 * ftp.h (ftp_size): Export it.
1977 * ftp.c (getftp): Use new ftp_size function if restoring
1978 transfer of a file with unknown size.
1980 2001-11-20 Hrvoje Niksic <hniksic@arsdigita.com>
1982 * url.c (parseurl): Don't depend on the now-obsolete TYPE.
1984 2001-11-19 Hrvoje Niksic <hniksic@arsdigita.com>
1986 * url.c (getproxy): Handle URL shorthands.
1988 2001-11-19 Hrvoje Niksic <hniksic@arsdigita.com>
1990 * main.c: Remove --wait / --waitretry backwards compatibility
1993 2001-11-19 Hrvoje Niksic <hniksic@arsdigita.com>
1995 * main.c (main): Use it.
1997 * url.c (rewrite_url_maybe): New function.
1999 2001-11-19 Hrvoje Niksic <hniksic@arsdigita.com>
2001 * url.c: Clean up handling of URL schemes.
2003 2001-05-13 Hrvoje Niksic <hniksic@arsdigita.com>
2005 * url.c: Get rid of `protostrings'.
2006 (skip_proto): Don't use protostrings.
2009 2001-11-18 Hrvoje Niksic <hniksic@arsdigita.com>
2011 * Makefile.in: Conditionally compile getopt.o.
2013 2001-11-18 Hrvoje Niksic <hniksic@arsdigita.com>
2015 * md5.h: Renamed to gnu-md5.h.
2017 * md5.c: Renamed to gnu-md5.c.
2021 * ftp-opie.c: Use the new macros.
2023 * sysdep.h: Define md5-related macros.
2025 * config.h.in: Define HAVE_SOLARIS_MD5 or HAVE_BUILTIN_MD5
2026 depending on which md5 implementation is used.
2028 2001-11-18 Hrvoje Niksic <hniksic@arsdigita.com>
2030 * res.c (res_register_specs): Initialize OLD and HP_OLD to appease
2033 2001-11-18 Hrvoje Niksic <hniksic@arsdigita.com>
2035 * http.c (gethttp): Print the whole response line when printing
2036 headers is requested.
2038 2001-05-12 Hrvoje Niksic <hniksic@arsdigita.com>
2040 * res.c: New file. Implement all RES-related code here.
2042 2001-11-18 Hrvoje Niksic <hniksic@arsdigita.com>
2044 * version.c: Wget 1.7.1 is released.
2046 2001-11-16 Hrvoje Niksic <hniksic@arsdigita.com>
2048 * headers.c (header_extract_number): Ignore trailing whitespace.
2050 2001-08-24 Ian Abbott <abbotti@mev.co.uk>
2052 * html-url.c (collect_tags_mapper): Fix bug converting links
2053 with -k option for tags with multiple link attributes by
2054 handling links in the order they appear.
2056 2001-08-15 Ian Abbott <abbotti@mev.co.uk>
2058 * ftp.c (ftp_loop_internal): Avoid a potential buffer overflow in
2059 the call to the 'rate' function by moving it past the error
2060 checking for the 'getftp' function return value.
2062 2001-11-16 Hrvoje Niksic <hniksic@arsdigita.com>
2064 * html-parse.c (advance_declaration): Use 0x22 instead of '"' or
2065 '\"'. Different compilers' assert macros are broken in different
2068 2001-09-29 Christian Fraenkel <c.fraenkel@gmx.net>
2070 * http.c (gethttp): print debug output for errors occuring during
2073 2001-11-16 Chris Seawood <cls@seawood.org>
2081 * sysdep.h: Support compilation under BEOS.
2083 2001-06-08 Edward J. Sabol <sabol@alderaan.gsfc.nasa.gov>
2085 * url.c (url_equal): Fix a memory leak when parseurl returns an
2086 error on the second URL. Also, since url_equal is not used at the
2087 moment, do not compile it.
2089 * url.h: Ditto for the prototype of url_equal.
2091 2001-11-16 Hrvoje Niksic <hniksic@arsdigita.com>
2093 * html-parse.c (map_html_tags): Support XML-style empty tags.
2095 2001-06-26 Hrvoje Niksic <hniksic@arsdigita.com>
2097 * wget.h (DO_REALLOC_FROM_ALLOCA): Check for do_realloc_newsize in
2098 loop condition because we're no longer setting SIZEVAR here.
2100 2001-06-26 Hrvoje Niksic <hniksic@arsdigita.com>
2102 * wget.h (DO_REALLOC_FROM_ALLOCA): Set SIZEVAR after the memcpy()
2103 call because it needs the old value.
2105 2001-06-18 Hrvoje Niksic <hniksic@arsdigita.com>
2107 * cookies.c (ATTR_NAME_CHAR): Allow almost any character to be in
2110 2001-06-18 Hrvoje Niksic <hniksic@arsdigita.com>
2112 * url.c (url_filename): Make sure that slashes that sneak in to
2113 u->file via query string get protected.
2114 (file_name_protect_query_string): New function.
2116 2001-06-14 Hrvoje Niksic <hniksic@arsdigita.com>
2118 * recur.c (recursive_retrieve): Also check undesirable_urls with
2121 2001-06-14 Hrvoje Niksic <hniksic@arsdigita.com>
2123 * http.c (gethttp): Search `.netrc' with real host, not the proxy
2126 2001-06-14 Hrvoje Niksic <hniksic@arsdigita.com>
2128 * sysdep.h (MAP_FAILED): Provide MAP_FAILED for systems that don't
2131 2001-06-09 Jan Prikryl <prikryl@cg.tuwien.ac.at>
2133 * ftp.h: Provide correct prototype for ftp_parse_ls().
2135 2001-06-04 Hrvoje Niksic <hniksic@arsdigita.com>
2137 * version.c: Wget 1.7 is released.
2139 2001-06-03 Karl Eichwalder <ke@suse.de>
2141 * ftp-ls.c (ftp_parse_ls): Fix typo.
2143 2001-05-27 Hrvoje Niksic <hniksic@arsdigita.com>
2145 * all: Update copyright information.
2147 2001-05-26 Hrvoje Niksic <hniksic@arsdigita.com>
2149 * http.c (gethttp): Indicate that the continued download failed
2152 2001-05-26 Hrvoje Niksic <hniksic@arsdigita.com>
2154 * version.c: Wget 1.7-pre1 is released.
2156 2001-05-26 Hrvoje Niksic <hniksic@arsdigita.com>
2158 * version.c: Updated version to 1.7-pre1.
2160 2001-05-14 Hrvoje Niksic <hniksic@arsdigita.com>
2162 * gen_sslfunc.c: Don't include <sys/time.h> directly.
2164 2001-05-14 Hrvoje Niksic <hniksic@arsdigita.com>
2166 * http.c (gethttp): Use real URL data for cookies, not the proxy
2169 2001-05-12 Hrvoje Niksic <hniksic@arsdigita.com>
2171 * main.c (print_help): Document `--no-http-keep-alive'.
2173 * utils.c (numdigit): Handle negative numbers *correctly*.
2175 * hash.c (make_nocase_string_hash_table): Use term "nocase" rather
2176 than the confusing "unsigned".
2178 * utils.c (string_set_contains): Renamed from string_set_exists.
2180 * hash.c (hash_table_contains): Renamed from hash_table_exists.
2182 * cookies.c: Move case-insensitive hash tables to hash.c.
2184 2001-05-09 Hrvoje Niksic <hniksic@arsdigita.com>
2186 * http.c (gethttp): Before concluding that the file is already
2187 fully retrieved, make sure that the file existed and `Range' was
2190 2001-05-09 Hrvoje Niksic <hniksic@arsdigita.com>
2192 * cookies.c (eliminate_dups): New function.
2193 (build_cookies_request): Use it.
2194 (build_cookies_request): Set chain_store_size after reallocating
2196 (check_domain_match): Annotated for easier future debugging.
2197 (store_cookie): In the debug message, print whether the cookie is
2200 2001-05-08 Hrvoje Niksic <hniksic@arsdigita.com>
2202 * http.c (http_loop): Reset no_truncate before deciding whether to
2204 (gethttp): Further clarify "-c conflicts with existing file" error
2205 message, based on input from Herold Heiko.
2207 2001-05-07 Hrvoje Niksic <hniksic@arsdigita.com>
2209 * http.c (http_loop): If restval is set, set no_truncate to 1
2212 2001-05-02 Jan Prikryl <prikryl@cg.tuwien.ac.at>
2214 * ftp-ls.c (ftp_parse_winnt_ls): Assure months are being correctly
2215 converted. Pointed out by <Stefan.Weil@de.heidelberg.com>.
2216 (ftp_parse_vms_ls): Ditto.
2218 2001-04-30 Hrvoje Niksic <hniksic@arsdigita.com>
2220 * init.c (cmd_address): Zero SIN before using it; apparently
2223 2001-04-29 Hrvoje Niksic <hniksic@arsdigita.com>
2225 * ftp.c (ftp_loop_internal): Don't set NO_TRUNCATE if the file is
2228 2001-04-29 Hrvoje Niksic <hniksic@arsdigita.com>
2230 * main.c (main): Make `--cookies' respect its argument.
2232 2001-04-28 Hrvoje Niksic <hniksic@arsdigita.com>
2234 * main.c (main): Removed undocumented option `--email-address'.
2236 * netrc.c: Use the latest read_whole_line.
2238 * init.c (defaults): Set opt.ftp_pass to "-wget@".
2240 * mswindows.c (pwd_cuserid): Ditto.
2242 * utils.c (pwd_cuserid): Removed.
2244 * host.c (ftp_getaddress): Removed.
2246 2001-04-28 Hrvoje Niksic <hniksic@arsdigita.com>
2248 (http_loop): Allocate space for filename_plus_orig_suffix with
2249 alloca; this is more efficient and removes the need to free it
2250 before each and every return.
2252 2001-04-28 Hrvoje Niksic <hniksic@arsdigita.com>
2254 * http.c (gethttp): Return RETRUNNEEDED when the retrieval is
2255 unneeded because the file is already there and fully downloaded,
2256 and -c is specified.
2257 (http_loop): Handle RETRUNNEEDED.
2259 * wget.h (uerr_t): New value RETRUNNEEDED.
2261 * http.c (http_loop): Set no_truncate for files that both exist
2263 (gethttp): Consider the download finished when restval >= contlen,
2264 not only when restval==contlen.
2265 (gethttp): Handle redirection before giving up due to -c.
2266 (gethttp): Clarify error message which explains that -c will not
2268 (gethttp): When returning CONTNOTSUPPORTED, don't forget to free
2269 the stuff that needs freeing and release the socket.
2271 2001-04-27 Hrvoje Niksic <hniksic@arsdigita.com>
2273 * main.c (print_help): Wget booleans accept "off", not "no".
2275 2001-04-27 Hrvoje Niksic <hniksic@arsdigita.com>
2277 * http.c (http_loop): If allow_cache is zero, always disable
2278 caching, not only when retrieving through proxy.
2282 * options.h (struct options): Rename proxy_cache to allow_cache.
2284 2001-04-27 Hrvoje Niksic <hniksic@arsdigita.com>
2286 * http.c (mktime_from_utc): Improve documentation.
2287 (http_atotm): Put format strings into a separate array.
2289 2001-04-27 Hrvoje Niksic <hniksic@arsdigita.com>
2291 * safe-ctype.h: Instead of throwing #error when isalpha is
2292 defined, redefine it to something that will throw a compile-time
2293 error if actually *used*. Do the same for the rest of the
2296 2001-04-26 Hrvoje Niksic <hniksic@arsdigita.com>
2298 * url.c (getproxy): Ignore empty proxy vars.
2300 2001-04-25 Hrvoje Niksic <hniksic@arsdigita.com>
2302 * http.c (http_loop): Would load cookies every time.
2304 * cookies.c (load_cookies): Handle cookies whose values contain
2307 2001-04-25 Hrvoje Niksic <hniksic@arsdigita.com>
2309 * utils.c: Define each DIGITS_* in one line.
2311 2001-04-25 Roger L. Beeman <beeman@cisco.com>
2313 * http.c (http_atotm): Initialize t.tm_isdst to 0.
2314 (mktime_from_utc): Prevent mktime() from having discontinuities at
2315 DST transition points.
2317 2001-04-25 Hrvoje Niksic <hniksic@arsdigita.com>
2319 * html-url.c (get_urls_html): Fix documentation.
2321 2001-04-25 Hrvoje Niksic <hniksic@arsdigita.com>
2323 * url.c (UNSAFE_CHAR): Reimplement using a static table.
2324 (url_init): Removed.
2325 (init_unsafe_char_table): Removed.
2327 2001-04-25 Hrvoje Niksic <hniksic@arsdigita.com>
2329 * snprintf.c (dopr): Replace ISDIGIT with '0' <= ch && ch <= '9'.
2331 2001-04-25 Hrvoje Niksic <hniksic@arsdigita.com>
2333 * utils.c: Document timer functions.
2335 * retr.c (rate): Use it.
2336 (rate): Print in GB/s if transfer rate exceeds 1 GB/s.
2338 * utils.c (wtimer_granularity): New function.
2340 2001-04-24 Hrvoje Niksic <hniksic@arsdigita.com>
2342 * retr.c (show_progress): Ditto.
2344 * ftp.c (getftp): Ditto.
2346 * http.c (gethttp): Use new timer functions.
2348 * utils.c (wtimer_allocate): New function.
2349 (wtimer_new): Ditto.
2350 (wtimer_delete): Ditto.
2351 (wtimer_reset): Ditto.
2352 (wtimer_elapsed): Ditto.
2354 2001-04-24 Hrvoje Niksic <hniksic@arsdigita.com>
2356 * utils.c (long_to_string): New, faster version. Favors smaller
2357 numbers; much of the calculation is now done at compile-time.
2359 2001-04-24 Hrvoje Niksic <hniksic@arsdigita.com>
2361 * utils.c (numdigit): Handle negative numbers.
2363 2001-04-23 Hrvoje Niksic <hniksic@arsdigita.com>
2365 * retr.c (show_progress): Print the download rate even when the
2366 percentages are not available.
2368 2001-04-21 Hrvoje Niksic <hniksic@arsdigita.com>
2370 * ftp.c (getftp): Adjust expected_bytes if the length is
2373 2001-04-14 Hrvoje Niksic <hniksic@arsdigita.com>
2375 * url.c: Don't declare `construct'.
2377 * hash.c (grow_hash_table): Speed up rehashing; inline storing of
2378 mappings to new locations.
2379 (hash_table_new): Make resize_threshold a field in the hash table,
2380 so we don't have to recalculate it in each hash_table_put.
2381 (grow_hash_table): Update resize_threshold.
2382 (MAX): Remove unused macro.
2383 (prime_size): Made static.
2385 2001-04-14 Hrvoje Niksic <hniksic@arsdigita.com>
2387 * retr.c (retrieve_url): Call uri_merge, not url_concat.
2389 * html-url.c (collect_tags_mapper): Call uri_merge, not
2392 * url.c (mkstruct): Use encode_string instead of xstrdup followed
2394 (path_simplify_with_kludge): Deleted.
2395 (contains_unsafe): Deleted.
2396 (construct): Renamed to uri_merge_1.
2397 (url_concat): Renamed to uri_merge.
2399 2001-04-13 Hrvoje Niksic <hniksic@arsdigita.com>
2401 * url.c (str_url): Use encode_string instead of the unnecessary
2403 (encode_string_maybe): New function, returns input string if no
2405 (encode_string): Call encode_string_maybe to do the dirty work,
2406 xstrdup if no work needed.
2408 2001-04-13 Hrvoje Niksic <hniksic@arsdigita.com>
2410 * wget.h (XDIGIT_TO_xchar): Define here.
2412 * url.c (decode_string): Use new name.
2413 (encode_string): Ditto.
2415 * http.c (XDIGIT_TO_xchar): Rename HEXD2asc to XDIGIT_TO_xchar.
2416 (dump_hash): Use new name.
2418 * wget.h: Rename ASC2HEXD and HEXD2ASC to XCHAR_TO_XDIGIT and
2419 XDIGIT_TO_XCHAR respectively.
2421 2001-04-13 Hrvoje Niksic <hniksic@arsdigita.com>
2423 * init.c: Include cookies.h.
2425 * cookies.h: Declare cookies_cleanup.
2427 * cookies.c (check_domain_match): Remove unused variable.
2428 (save_cookies): Remove extraneous argument from debug statement.
2430 * host.c (same_host): Don't call skip_url.
2432 * url.c (skip_url): Removed. Removed its calls from various
2435 2001-04-13 Hrvoje Niksic <hniksic@arsdigita.com>
2437 * cookies.c (unsigned_string_hash): Use the new code in
2438 string_hash as reference.
2440 * hash.c (hash_table_map): Allow deletion and change of the
2441 element processed by MAPFUN.
2442 (string_hash): Use the function from glib.
2444 2001-04-12 Hrvoje Niksic <hniksic@arsdigita.com>
2446 * config.h.in: Include #undef stub.
2448 * hash.c (hash_table_remove): Rewrite to actually clear deleted
2449 entries instead of just marking them as deleted.
2451 2001-04-12 Hrvoje Niksic <hniksic@arsdigita.com>
2453 * hash.h: Declare hash_table_get_pair and hash_table_count.
2455 2001-04-12 Hrvoje Niksic <hniksic@arsdigita.com>
2457 * cookies.c: Declare http_atotm.
2459 2001-04-12 Hrvoje Niksic <hniksic@arsdigita.com>
2461 * ftp-ls.c (ftp_parse_unix_ls): Use octal constants for
2462 permissions. A compiler that doesn't accept octal constants is
2463 seriously broken and shouldn't be used -- octal constants were
2466 2001-01-20 Karl Eichwalder <ke@suse.de>
2468 * Makefile.in: Provide and use DESTDIR according to the Coding
2471 2001-04-12 Hrvoje Niksic <hniksic@arsdigita.com>
2473 * ftp-ls.c (ftp_parse_vms_ls): Make seconds optional in time
2476 2001-04-11 Hrvoje Niksic <hniksic@arsdigita.com>
2478 * url.c (parseurl): Don't strip trailing slash when u->dir is "/"
2479 because that strips the *leading* slash, thus forcing relative
2482 2001-04-10 Jan Prikryl <prikryl@cg.tuwien.ac.at>
2484 * ftp.c (getftp): Convert initial FTP directory from VMS to UNIX
2485 notation for VMS servers.
2486 (ftp_retrieve_dirs): Do not prepend '/' to f->name when
2487 odir is an empty string.
2489 2001-04-10 Jan Prikryl <prikryl@cg.tuwien.ac.at>
2491 * ftp-ls.c (ftp_parse_winnt_ls): Made the fix for AM/PM more
2492 effective. Suggested by Edward J. Sabol.
2494 2001-04-10 Hrvoje Niksic <hniksic@arsdigita.com>
2496 * cookies.c (build_cookies_request): Use and sort cookies from all
2498 (build_cookies_request): Check for duplicates before generating
2499 the `Cookies' header.
2501 * main.c (main): Don't load cookies here.
2502 (main): Make loadcookies and savecookies call the correct command.
2504 * http.c (http_loop): Load cookies on-demand.
2506 2001-04-09 Hrvoje Niksic <hniksic@arsdigita.com>
2508 * http.c (gethttp): Fix indentation of SSL ifdef.
2510 2001-04-09 Hrvoje Niksic <hniksic@arsdigita.com>
2512 * ftp.c (ftp_retrieve_dirs): Don't forcibly prepend "/" to u->dir;
2513 that hack is no longer necessary.
2514 (getftp): Prepend initial directory to *non*-absolute u->dir's.
2516 2001-04-09 Hrvoje Niksic <hniksic@arsdigita.com>
2518 * init.c (cmd_file): New function.
2519 (enable_tilde_expansion): New variable.
2520 (run_wgetrc): Use it.
2523 2001-04-08 Hrvoje Niksic <hniksic@arsdigita.com>
2525 * init.c: Include cookie-related options.
2527 * main.c (main): Include cookie-specific options.
2528 (main): Load cookies before download is finished.
2529 (main): Save cookies when done.
2531 * http.c (gethttp): Process the `Set-Cookie' header.
2532 (gethttp): Include cookies in the response.
2534 * cookies.c: New file.
2536 2001-04-08 Hrvoje Niksic <hniksic@arsdigita.com>
2538 * utils.c (datetime_str): New function.
2540 2001-04-08 Jan Prikryl <prikryl@cg.tuwien.ac.at>
2542 * ftp-ls.c (ftp_parse_winnt_ls): The AM/PM change did assume
2543 12:01PM == 00:01, which was obviously wrong. Taken care of this
2546 * ChangeLog: Removed an excess conflict marker. Reformatted the
2547 entry by Philipp Thomas from 2001-03-09.
2549 * ftp-ls.c (ftp_parse_winnt_ls): Ensure that adjusted PM hours lay
2550 between 0 and 23. Elminate unused variable `sec'.
2552 2001-04-08 Hrvoje Niksic <hniksic@arsdigita.com>
2554 * hash.c (hash_table_count): New function.
2556 2001-04-06 Hrvoje Niksic <hniksic@arsdigita.com>
2558 * utils.c (read_file): Cast MAP_FAILED to char *. Enforced by
2561 2001-04-06 Hrvoje Niksic <hniksic@arsdigita.com>
2563 * config.h.in: Oops, do the namespace tweaks only on systems we
2566 2001-04-06 Hrvoje Niksic <hniksic@arsdigita.com>
2568 * hash.c: Include <string.h>.
2570 2001-04-06 Hrvoje Niksic <hniksic@arsdigita.com>
2572 * config.h.in: Define "compilation environment" options that work
2573 under Linux and Solaris. To be reviewed on other OS'es.
2575 2001-04-06 Hrvoje Niksic <hniksic@arsdigita.com>
2577 * http.c (gethttp): Prepend literal newline with `\n\'.
2579 2001-04-06 Hrvoje Niksic <hniksic@arsdigita.com>
2581 * sysdep.h: Don't define VERY_LONG_FORMAT.
2583 * utils.c (very_long_to_string): New function.
2584 (legible_very_long): Use it; don't use VERY_LONG_FORMAT.
2586 2001-04-04 Christian Fraenkel <christian.fraenkel@gmx.net>
2588 * url.c (parse_uname): Would run past the end of the string if the
2589 username was present, but the URL did not contain a slash, e.g.
2590 http://foo:bar@myhost.
2592 2001-04-03 KOJIMA Hajime <kjm@rins.ryukoku.ac.jp>
2594 * http.c (http_atotm): Use %A instead of %a to match full
2595 weekday. (On most systems there is no difference.)
2597 2001-04-03 Paul Bludov <paul@ozero.net>
2599 * mswindows.c (sleep): Use SleepEx() instead of Sleep().
2600 (ws_changetitle): Use alloca() instead of malloc() to avoid memory
2602 (ws_mypath): Use GetModuleFileName instead of argv[0].
2603 (ws_startup): Use data.wVersion for comparison.
2605 2001-04-02 Hrvoje Niksic <hniksic@arsdigita.com>
2607 * http.c (http_loop): Ditto.
2609 * ftp.c (ftp_loop_internal): Made the check whether to continue
2610 retrieval `-O'-friendly.
2612 2001-04-02 Hrvoje Niksic <hniksic@arsdigita.com>
2614 * netrc.c (parse_netrc): Don't trim the line endings explicitly;
2615 they will be handled as whitespace.
2616 (parse_netrc): Correctly handle lines that end with whitespace.
2618 2001-04-02 Hrvoje Niksic <hniksic@arsdigita.com>
2620 * retr.c (retrieve_url): New variable global_download_count used
2621 to identify first retrieval.
2623 * ftp.c (getftp): Ditto.
2625 * http.c (gethttp): Rewind opt.dfp only on first retrieval.
2627 2001-04-02 Hrvoje Niksic <hniksic@arsdigita.com>
2629 * init.c (cmd_address): Heap-allocate the address that gets stored
2630 to CLOSURE. Old code would simply assign an address on the stack.
2632 2001-04-01 Nicolas Lichtmaier <nick@debian.org>
2634 * ftp.c (ftp_get_listing): Propagate error status.
2635 (ftp_retrieve_glob): Use it.
2638 2001-04-01 Nicolas Lichtmaier <nick@debian.org>
2640 * main.c (main): Add -C to the string that is the third arg to
2643 2001-04-01 Hrvoje Niksic <hniksic@arsdigita.com>
2645 * ftp.c (getftp): Don't start the download from scratch if `-c'
2646 was specified, but the file is already fully downloaded.
2648 * http.c (gethttp): Don't truncate a pre-existing file if `-c' was
2649 specified and the server doesn't support continued download.
2650 (gethttp): Don't start the download from scratch if `-c' was
2651 specified, but the file is already fully downloaded.
2653 2001-03-31 Hrvoje Niksic <hniksic@arsdigita.com>
2655 (recursive_retrieve): Don't clear the hash tables at this point at
2656 all; it interferes with the normal operation of register_download.
2658 2001-03-31 Hrvoje Niksic <hniksic@arsdigita.com>
2660 * recur.c (recursive_retrieve): Clear the hash tables only when
2663 2001-03-31 Hrvoje Niksic <hniksic@arsdigita.com>
2665 * http.c (gethttp): Make sure the socket is closed with
2666 CLOSE_INVALIDATE before we have drained the body.
2668 2001-03-31 Hrvoje Niksic <hniksic@arsdigita.com>
2670 * retr.c (retrieve_url): Call register_download() for downloaded
2671 files and register_html() for downloaded HTML files.
2673 * recur.c (register_download): New function; register here that a
2674 file has been downloaded, rather than in recursive_retrieve().
2675 (register_html): New function; enqueue the location of HTML files
2676 here rather than in recursive_retrieve().
2678 2001-03-31 Hrvoje Niksic <hniksic@arsdigita.com>
2680 * main.c (print_help): Use multiple fputs instead of a single ugly
2682 (main): Consistently assign numbers >128 to options without a
2683 corresponding character.
2685 2001-03-09 Philipp Thomas <pthomas@suse.de>
2687 * safe-ctype.h: New file. Locale independent ctype.h replacement
2688 taken from libiberty.
2690 * safe-ctype.c: New file. Tables for above.
2692 * Makefile.in: Add safe-ctype$o to OBJS. Add dependencies for
2695 * cmpt.c: Remove include of ctype.h. Use ISSPACE instead of
2698 * ftp-basic.c: Don't include ctype.h.
2700 * ftp-ls.c: Likewise.
2704 * headers.c: Likewise.
2708 * html-parse.c: Likewise.
2710 * html-url.c: Likewise.
2716 * main.c: Likewise. Set LC_CTYPE along with LC_MESSAGES.
2718 * netrc.c: Likewise.
2720 * recur.c: Likewise.
2724 * snprintf.c: Replace ctype.h with safe-ctype.h. Use ISDIGIT
2727 * sysdep.h: Remove defines of ctype macros as they aren't needed
2730 * url.c: Don't include ctype.h.
2732 * utils.c: Likewise.
2734 * wget.h: Include safe-ctype.h.
2736 2001-03-27 Dan Harkless <wget@harkless.org>
2738 * Makefile.in: Moved top_builddir out of "User configuration
2739 section" of top Makefile and analogous spot in this one.
2741 2001-03-17 Dan Harkless <wget@harkless.org>
2743 * Makefile.in: Include @SSL_INCLUDES@ substition in INCLUDES.
2744 Define top_builddir. Link wget with libtool so the user doesn't
2745 have to supply a bunch of custom environment variables to
2746 correctly link with the OpenSSL shared libraries.
2748 2001-03-06 Hack Kampbjorn <hack@hackdata.com>
2750 * http.c (gethttp): skip :port in host header if it is the
2751 DEFAULT_HTTPS_PORT when using SSL.
2753 * url.c: move the #define of DEFAULT_HTTP_PORT, DEFAULT_FTP_PORT
2754 and DEFAULT_HTTPS_PORT to the header file so it can be use in the
2758 2001-03-01 Jonas Jensen <bones@huleboer.dk>
2760 * retr.c (show_progress): Correctly calculate the number of bytes
2761 in the first line of the download that have been actually
2762 downloaded in this run.
2764 2001-02-23 Dan Harkless <wget@harkless.org>
2766 * main.c (print_help): --help documentation for -N said it would
2767 re-download files if they had the _same_ timestamp on server.
2768 (print_help): -nr belongs in "FTP options" section of --help
2769 output, not "Recursive retrieval" section. Alphabetized FTP
2770 options by long option name.
2772 2001-02-16 Dan Harkless <wget@harkless.org>
2774 * init.c (commands): Hack Kampbjørn <hack@hackdata.com> discovered
2775 that "httpsproxy" had been inserted into commands[] out of
2776 alphabetical order, causing "BUG: unknown command `httpuser'".
2778 2001-02-13 Jan Prikryl <prikryl@cg.tuwien.ac.at>
2780 * ftp-ls.c (ftp_parse_ls): Added support of ST_MACOS (Unix-like
2781 listing without correct permissons).
2783 * ftp.h (stype): Added ST_MACOS to identify the NetPresenz MacOS
2786 * ftp.c (ftp_retrieve_list): New mirroring logic: A remote file
2787 shall be donwloaded only when it's newer than the local copy or
2788 when it has the same timeestamp but its size is different. ST_VMS
2789 and ST_MACOS as special cases that lie about file size.
2791 * ftp-ls.c (ftp_parse_ls): Support for ST_MACOS.
2793 * Makefile.in: Removed dependency on ftpparse library due to unclear
2794 copyright issues and absence of any feedback to our queries.
2796 * ftp-ls.c: Removed dependency on ftpparse library due to unclear
2797 copyright issues and absence of any feedback to our queries.
2798 (ftp_parse_ls): Added a warning message when remote server system
2799 does not seem to be suported by wget.
2800 (ftp_parse_vms_ls): New function for parsing VMS ftp
2801 server listing output.
2802 (clean_line): New function responsible for removing
2803 end-of-line characters from FTP listing texts.
2805 * ftp.c (getftp): Global variables pwd and host_type are now
2806 member of the ccon structure under names ccon.id and ccon.rs.
2808 * ftp.h (struct ccon): Added formed global variables from ftp.c,
2809 enum stype rs (remote system identification) and char *id (initial
2810 working directory), as suggested by Hrvoje.
2812 * url.c (parse_uname): Added support for passwords containing '@'
2814 (skip_uname): Ditto.
2816 2001-02-11 Hrvoje Niksic <hniksic@arsdigita.com>
2818 * ftp.c (ftp_loop): Reset con.
2820 2001-01-06 Jan Prikryl <prikryl@cg.tuwien.ac.at>
2822 * url.c (parse_uname): Added support for passwords containing '@'
2824 (skip_uname): Ditto.
2826 2001-02-11 Hack Kampbjørn <hack@hackdata.com>
2828 * url.c (parseurl): Debug-print u->ftp_type.
2830 2001-02-11 Hrvoje Niksic <hniksic@arsdigita.com>
2832 * ftp.c (ftp_loop_internal): Disable padding.
2835 * http.c (http_loop): Disable padding.
2837 * retr.c (show_progress): Use it to enable padding.
2839 * retr.c (rate): Optional parameter PAD for padding the rate.
2841 2001-02-10 Hrvoje Niksic <hniksic@arsdigita.com>
2843 * retr.c (show_progress): Make sure that the last output line
2846 2001-02-10 Jonas Jensen <bones@huleboer.dk>
2848 * retr.c (show_progress): Print the download rate along with the
2850 Along with Anders Thorsby <anders@thorsby.dk>.
2852 2001-02-10 Tim Mooney <mooney@dogbert.cc.ndsu.NoDak.edu>
2854 * ftp.h: Rename enums `command' to `wget_ftp_command' and
2855 `fstatus' to `wget_ftp_status' because old names clash with Tru64
2858 2001-02-08 Christian Fraenkel <christian.fraenkel@gmx.net>
2860 * gen_sslfunc.c: verify_callback is now static
2862 * gen_sslfunc.c (init_ssl): load certificate if specified
2864 * gen_sslfunc.c (ssl_printerr): new function
2866 * init.c: added new --sslcertfile and --sslcertkey switches
2872 * http.c (gethttp): abort when init_ssl fails
2874 2001-01-23 Herold Heiko <Heiko.Herold@previnet.it>
2876 * mswindows.h: Include <malloc.h>; it's needed for alloca().
2878 2001-01-10 Dan Harkless <wget@harkless.org>
2880 * url.c (str_url): Clarified this function's comment header after
2881 Hrvoje answered my question on the list as to when hide != 1.
2882 Also Hrvoje pointed out I need to use xstrdup() on the string literal.
2884 2001-01-06 Hrvoje Niksic <hniksic@arsdigita.com>
2886 * connect.c (bindport): Declare addrlen as int. Diagnosed by
2887 Drazen Kacar <dave@arsdigita.com>.
2890 2001-01-09 Dan Harkless <wget@harkless.org>
2892 * html-url.c: A bunch of fixup of `--page-requisites'-related
2893 comments to reflect Hrvoje's changes to my code when transplanting
2894 it into this new file, to fix spelling mistakes, to clarify, etc.
2896 * url.c (write_backup_file): Clarified a comment.
2897 (str_url): Henrik van Ginhoven pointed out on the list that we
2898 shouldn't give away the number of characters in the password by
2899 replacing each character with a 'x'. Use "<password>" instead.
2901 * ftp.c (ftp_retrieve_dirs): The bug where recursion into FTP
2902 directories didn't work if logging in put you in a directory other
2903 than "/" is fixed now. Removed the comment here warning of the bug.
2905 * main.c (print_help): --continue's description was misleading.
2906 We don't "restart", we "resume". Also, better to say
2907 "partially-downloaded file" rather than just "existing file".
2909 2001-01-06 Dan Harkless <wget@harkless.org>
2911 * ChangeLog: The '[Not in 1.6 branch.]'s were decided not to be
2912 the best way to go about my aim. Removed them in favor of:
2914 * ChangeLog-branches/1.6_branch.ChangeLog: New file.
2916 2001-01-04 Hrvoje Niksic <hniksic@arsdigita.com>
2918 * url.c (replace_attr): New function, to be used by both
2919 TO_COMPLETE and TO_RELATIVE case in convert_links.
2920 (find_fragment): New function for finding URL fragments.
2921 (replace_attr): Better handle the case where the original string
2922 is not quoted. Use find_fragment.
2923 (convert_links): Use replace_attr().
2925 2000-12-31 Dan Harkless <wget@harkless.org>
2927 * ChangeLog: Since this flat file doesn't have multiple branches,
2928 looking at the dates would make you think that things went into
2929 1.6 that actually just went into the 1.7-dev branch. Added "[Not
2930 in 1.6 branch.]" where appropriate to clarify.
2932 2000-12-30 Dan Harkless <wget@harkless.org>
2934 * ftp.c, http.c: Applied Hack Kampbjørn <hack@hackdata.com>'s
2935 patch to deal with h_errno not being defined in netdb.h under Cygwin.
2937 2000-12-18 Csaba Raduly <csaba.raduly@sophos.com>
2939 * sysdep.h: Include <malloc.h> and <io.h> under Watcom.
2941 2000-12-17 Igor Khristophorov <igor@atdot.org>
2943 * http.c (check_end): Fix test for '+' or '-'.
2945 2000-12-17 Hrvoje Niksic <hniksic@arsdigita.com>
2947 * url.c (parseurl): Rename inner loop var from i to ind to avoid
2948 clash with the function top-level-declared variable i.
2949 (str_url): Likewise, rename inner-loop i to j.
2951 * recur.c (parse_robots): Don't declare LEN at top of function.
2952 (robots_match): Renamed parameter FORBIDDEN to avoid hiding of
2955 * main.c (main): Change erroneous use of bitwise and to logical.
2957 * init.c (cmd_address): Don't heap-allocate `sin'; it can be on
2958 the stack because it will be copied to closure.
2960 Thanks to Csaba Raduly's run of PC-LINT over the sources.
2962 2000-12-17 Hrvoje Niksic <hniksic@arsdigita.com>
2964 * http.c (basic_authentication_encode): Use xmalloc(), not
2965 malloc(). Thanks to Csaba Raduly's run of PC-LINT over the
2968 2000-12-17 Csaba Raduly <csaba.raduly@sophos.com>
2970 * sysdep.h: Test for __EMX__ rather than for EMXOS2 for OS/2
2973 2000-12-17 Hrvoje Niksic <hniksic@arsdigita.com>
2975 * mswindows.c: Include <errno.h>.
2977 * gen_sslfunc.c: Include <errno.h>.
2979 * ftp-basic.c: Don't attempt to declare errno or h_errno because
2982 * main.c: Include <errno.h> because errno is used.
2986 * http.c: Include <netdb.h> for h_errno.
2988 2000-12-13 Hrvoje Niksic <hniksic@arsdigita.com>
2990 * html-parse.c (advance_declaration): MSVC assert() chokes on
2991 '\"'. Use '"' instead.
2993 2000-12-11 Hrvoje Niksic <hniksic@arsdigita.com>
2995 * utils.c (xfree_real): Removed.
2996 (xfree_debug): Just call free().
2998 * wget.h (xfree): Make it an alias for free.
3000 2000-12-11 Hrvoje Niksic <hniksic@arsdigita.com>
3002 * http.c (http_loop): Furthermore, touch output_document only if
3003 it is known to be an existing regular file.
3005 2000-12-11 Hrvoje Niksic <hniksic@arsdigita.com>
3007 * ftp.c (ftp_retrieve_list): Ditto.
3009 * http.c (http_loop): Touch output_document if that is used for
3012 2000-12-06 Hrvoje Niksic <hniksic@arsdigita.com>
3014 * http.c: Include gen_sslfunc.h after including Wget's headers.
3015 (persistent_available_p): Needed coma before `int ssl'.
3017 2000-12-06 Hrvoje Niksic <hniksic@arsdigita.com>
3019 * ftp.c (ftp_loop_internal): Ditto.
3021 * http.c (http_loop): Use it.
3023 * retr.c (sleep_between_retrievals): New function that handles the
3024 logic of opt.wait and opt.waitretry.
3026 2000-12-06 Hrvoje Niksic <hniksic@arsdigita.com>
3028 * rbuf.h: Implement only a single version of RBUF_READCHAR, using
3029 rbuf_read_bufferful when the buffer is depleted.
3031 * rbuf.c (rbuf_read_bufferful): New function.
3033 2000-12-06 Hrvoje Niksic <hniksic@arsdigita.com>
3035 * gen_sslfunc.h: Use ansi2knr style function declarations.
3037 * gen_sslfunc.c: Reformat according to the GNU coding standards.
3038 More should be done.
3040 * http.c (persistent_available_p): Place the cheap SSL test nearer
3041 the top of the function.
3042 (CLOSE_FINISH, CLOSE_INVALIDATE): Define only one version of each.
3044 2000-12-05 Hrvoje Niksic <hniksic@arsdigita.com>
3046 * url.c (init_unsafe_char_table): Reinstate space as an unsafe
3049 2000-12-03 Christian Fraenkel <christian.fraenkel@gmx.net>
3051 * Makefile.in: added gen_sslfunc object
3052 * config.h.in: added HAVE_SSL define
3053 * connect.c: changed select_fd from static int to int
3055 * gen_sslfunc.h: New file
3056 * gen_sslfunc.c: ditto
3057 * http.c: added HTTPS fuctionality
3060 * init.c: added opt.httpsproxy
3062 * rbuf.h: added alternate rbuf struct
3063 * wget.h: added CONSSLERR
3066 * http.c: Added HTTPS fuctionality.
3072 * init.c: Added opt.httpsproxy.
3076 * rbuf.h: Added alternate rbuf struct.
3078 * wget.h: Added CONSSLERR.
3082 2000-11-30 Jan Prikryl <prikryl@cg.tuwien.ac.at>
3084 * ftp-ls.c (ftp_parse_unix_ls): Added second parameter
3085 "ignore_perms" to ignore file and directory permissions for
3086 Windows NT FTP server listings.
3087 (ftp_parse_winnt_ls): New function.
3088 (ftp_parse_ls): Parses UNIX and Windows NT listings
3089 separately. Simple heuristics for distinguishing between UNIX and
3090 MS-DOS-like FTP listing provided by Windows NT FTP service.
3092 2000-11-18 Jan Prikryl <prikryl@cg.tuwien.ac.at>
3094 * ftpparse.c, ftpparse.h: New files.
3096 * ftp-ls.c (ftp_parse_ls): Use ftp_parse_unix_ls for UNIX servers
3097 only. Use ftp_parse_nonunix_ls otherwise.
3098 (ftp_parse_nonunix_ls): Stub to the ftpparse library handling all
3101 * ftp.h (stype): New enum, distinguishes UNIX, VMS, and "other"
3104 * ftp.c: New static wariables host_type, pwd, and pwd_len.
3105 (getftp): Support for VMS. Support for FTP servers that do not
3106 place you in the root directory after login.
3107 (ftp_retrieve_list): VMS is silent about the real file size, issue
3108 a more appropriate message.
3109 (ftp_get_listing): Pass host_type to ftp_parse_ls.
3111 * ftp-basic.c (ftp_pwd, ftp_syst): New functions.
3113 2000-11-30 Jan Prikryl <prikryl@cg.tuwien.ac.at>
3115 * ftp-ls.c (ftp_parse_unix_ls): Added second parameter
3116 "ignore_perms" to ignore file and directory permissions for
3117 Windows NT FTP server listings.
3118 (ftp_parse_winnt_ls): New function.
3119 (ftp_parse_ls): Parses UNIX and Windows NT listings
3120 separately. Simple heuristics for distinguishing between UNIX
3121 and MS-DOS-like FTP listing provided by Windows NT FTP service.
3123 2000-11-29 John Summerfield <summer@OS2.ami.com.au>
3125 * netrc.c (parse_netrc): Get rid of line ending.
3127 2000-11-25 Hrvoje Niksic <hniksic@arsdigita.com>
3129 * ftp.c (ftp_retrieve_list): Undo typo "fix" until resolution by
3132 2000-11-24 Karl Eichwalder <ke@suse.de>
3134 * main.c (print_help): Untabify.
3136 2000-11-23 Hrvoje Niksic <hniksic@arsdigita.com>
3138 * utils.c (xrealloc_debug): Do the unregister/register thing only
3139 if the pointer has actually changed.
3140 (xmalloc_real): Declare `static' in DEBUG_MALLOC builds.
3141 (xfree_real): Ditto.
3142 (xrealloc_real): Ditto.
3143 (xstrdup_real): Ditto.
3145 2000-11-22 Hrvoje Niksic <hniksic@arsdigita.com>
3147 * ftp.c (getftp): ftp_getaddress() returns a malloc'ed copy of the
3148 string; no need to strdup() it.
3149 (getftp): Make pwd_len a local variable.
3150 (ftp_loop): Free PWD before returning.
3152 * init.c (cleanup): Free opt.ftp_pass only if it's non-NULL.
3154 2000-11-22 Hrvoje Niksic <hniksic@arsdigita.com>
3156 * all: Use xfree() instead of free.
3158 * utils.c (xfree): New function.
3160 2000-11-21 Hrvoje Niksic <hniksic@arsdigita.com>
3162 * url.c (convert_links): HTML-quote the converted string.
3164 * utils.c (html_quote_string): Move here from ftp-ls.c
3165 (html_quote_string): Make non-static; declare in utils.h.
3166 (html_quote_string): Convert SP to  .
3168 2000-11-21 Hrvoje Niksic <hniksic@arsdigita.com>
3170 * ftp.c (getftp): Reformat Jan's code according to GNU coding
3171 standards; remove (debugging?) printf's; use '\0' for the ASCII
3172 zero character. Use alloca() instead of malloc() for
3173 inter-function temporary allocations.
3175 2000-11-18 Jan Prikryl <prikryl@cg.tuwien.ac.at>
3177 * ftpparse.c, ftpparse.h: New files.
3179 * ftp-ls.c (ftp_parse_ls): Use ftp_parse_unix_ls for UNIX servers
3180 only. Use ftp_parse_nonunix_ls otherwise.
3181 (ftp_parse_nonunix_ls): Stub to the ftpparse library handling all
3184 * ftp.h (stype): New enum, distinguishes UNIX, VMS, and "other"
3187 * ftp.c: New static wariables host_type, pwd, and pwd_len.
3188 (getftp): Support for VMS. Support for FTP servers that do not
3189 place you in the root directory after login.
3190 (ftp_retrieve_list): VMS is silent about the real file size, issue
3191 a more appropriate message.
3192 (ftp_get_listing): Pass host_type to ftp_parse_ls.
3194 * ftp-basic.c (ftp_pwd, ftp_syst): New functions.
3196 2000-11-21 Hrvoje Niksic <hniksic@arsdigita.com>
3198 * hash.c (hash_table_put): Don't overwrite deleted mappings.
3200 2000-11-21 Hrvoje Niksic <hniksic@arsdigita.com>
3202 * hash.c (find_mapping): New function.
3203 (hash_table_get): Use it.
3204 (hash_table_get_pair): Ditto.
3205 (hash_table_exists): Ditto.
3206 (hash_table_remove): Ditto.
3207 (hash_table_remove): Really delete the entry if the mapping
3208 following LOCATION is empty.
3210 * utils.c (string_set_add): Check whether the element has existed
3213 * hash.c (hash_table_get_pair): New function.
3215 2000-11-20 Hrvoje Niksic <hniksic@arsdigita.com>
3217 * http.c (http_process_type): Ignore trailing whitespace; use
3220 * recur.c (recursive_retrieve): Use the new `convert' field.
3221 (convert_all_links): Ditto.
3222 (convert_all_links): Don't respect meta_disallow_follow.
3224 * html-url.c (handle_link): Fill out link_relative_p and
3227 * url.h (struct _urlpos): Make elements more readable.
3229 * recur.c (recursive_retrieve): Call slist_prepend instead of
3231 (convert_all_links): Call slist_nreverse before iterating through
3234 * utils.c (slist_prepend): New function.
3235 (slist_nreverse): Ditto.
3237 2000-11-20 Hrvoje Niksic <hniksic@arsdigita.com>
3239 * http.c (check_end): Constify.
3241 2000-11-20 Hrvoje Niksic <hniksic@arsdigita.com>
3243 * http.c (http_loop): If username and password are known, try the
3244 `Basic' authentication scheme by default.
3246 * connect.h: Declare test_socket_open.
3248 2000-11-20 Hrvoje Niksic <hniksic@arsdigita.com>
3250 * version.c: Bump version from 1.5.3+dev to 1.7-dev.
3252 2000-11-20 Hrvoje Niksic <hniksic@arsdigita.com>
3254 * http.c (gethttp): Don't use the return value of sprintf().
3255 (gethttp): Inhibit keep-alive if opt.http_keep_alive is 0.
3257 2000-11-20 Hrvoje Niksic <hniksic@arsdigita.com>
3259 * recur.c (recursive_retrieve): Print the "so we don't load"
3260 debugging message only if we really don't load.
3262 * http.c (gethttp): Inhibit keep-alive if proxy is being used.
3263 (gethttp): Don't request keep-alive if keep-alive is inhibited.
3265 2000-11-19 Hrvoje Niksic <hniksic@arsdigita.com>
3267 * http.c (gethttp): Make the HTTP persistent connections more
3270 2000-11-19 Hrvoje Niksic <hniksic@arsdigita.com>
3272 * retr.c (get_contents): If use_expected, make sure that the
3273 appropriate amount of data is being read.
3275 * http.c (gethttp): Check for both `Keep-Alive: ...' and
3276 `Connection: Keep-Alive'.
3278 * wget.h (DEBUGP): Call debug_logprintf only if opt.debug is
3281 2000-11-19 Hrvoje Niksic <hniksic@arsdigita.com>
3283 * http.c (connection_available_p): Use it.
3285 * connect.c (test_socket_open): New function.
3287 * http.c (gethttp): Support persistent connections. Based on the
3288 ideas, and partly on code, by Sam Horrocks <sam@daemoninc.com>.
3289 (register_persistent): New function.
3290 (connection_available_p): Ditto.
3291 (invalidate_connection): Ditto.
3293 2000-11-19 Hrvoje Niksic <hniksic@arsdigita.com>
3295 * url.c (convert_links): Handle UREL2ABS case.
3297 * recur.c (recursive_retrieve): Instead of the list
3298 urls_downloaded, use hash tables dl_file_url_map and
3300 (convert_all_links): Use them to retrieve data.
3302 * host.c (clean_hosts): Free the hash tables.
3304 * main.c (private_initialize): Call host_init().
3306 * host.c (store_hostaddress): Use a saner, hash table-based data
3309 (host_init): Initialize the hash tables.
3311 2000-11-18 Hrvoje Niksic <hniksic@arsdigita.com>
3313 * utils.c (slist_append): Eviscerate NOSORT. Hash tables are now
3314 used for what the sorted slists used to be used for.
3315 (slist_contains): Don't rely on the list being sorted.
3316 (slist_append): Simplify the code.
3318 * recur.c (recursive_cleanup): Use free_string_set.
3320 * utils.c (string_set_add, string_set_exists, string_set_free):
3321 New functions for easier freeing of hash tables whose keys are
3324 * recur.c (recursive_retrieve): Use the hash table functions for
3325 storing undesirable URLs.
3329 2000-11-17 Hrvoje Niksic <hniksic@arsdigita.com>
3331 * main.c (private_initialize): Call url_init.
3332 (main): Call private_initialize.
3334 * url.c (unsafe_char_table): New table.
3335 (UNSAFE_CHAR): Use it.
3336 (init_unsafe_char_table): New function.
3337 (url_init): New function; call init_unsafe_char_table.
3339 2000-11-16 Hrvoje Niksic <hniksic@arsdigita.com>
3341 * mswindows.h: Define snprintf and vsnprintf to _snprintf and
3342 _vsnprintf respectively.
3344 2000-11-15 Hrvoje Niksic <hniksic@arsdigita.com>
3346 * config.h.in: Do the _XOPEN_SOURCE and _SVID_SOURCE things only
3349 2000-11-15 Hrvoje Niksic <hniksic@arsdigita.com>
3351 * html-url.c (handle_link): Handle HTML fragment identifiers.
3353 * recur.c (recursive_retrieve): If norobot info is respected and
3354 the file is specified not to be followed by robots, respect that.
3356 * html-url.c (collect_tags_mapper): Handle <meta name=robots
3357 content=X>. For us the important cases are where X is NONE or
3358 where X contains NOFOLLOW.
3359 (get_urls_html): Propagate that information to the caller.
3361 2000-11-13 Hrvoje Niksic <hniksic@arsdigita.com>
3363 * url.c (convert_links): Unlink the file we might be reading from
3364 before writing to it.
3365 (convert_links): Use alloca instead of malloc for
3366 filename_plus_orig_suffix.
3368 2000-11-12 Hrvoje Niksic <hniksic@arsdigita.com>
3370 * host.c (realhost): Add HOST to the list with quality==0 only if
3371 it wasn't already there.
3372 Based on analysis by Lu Guohan <feng@public.bjnet.edu.cn>.
3374 2000-11-10 Hrvoje Niksic <hniksic@arsdigita.com>
3376 * url.c (get_urls_file): Ditto.
3377 (convert_links): Ditto.
3379 * html-url.c (get_urls_html): Use read_file() instead of
3382 * utils.c (read_file): New function, instead of the old
3384 (read_file_free): Ditto.
3386 * url.c (findurl): Search only for the supported protocols.
3387 (convert_links): Use fwrite() when writing out a region of
3390 2000-11-10 Hrvoje Niksic <hniksic@arsdigita.com>
3392 * ftp-ls.c: Move html_quote_string and ftp_index here.
3394 * url.c: Remove get_urls_html, since that's now in html-url.c.
3396 * html-url.c: New file.
3398 * html-parse.c: New file.
3400 2000-11-10 Hrvoje Niksic <hniksic@arsdigita.com>
3402 * init.c (run_wgetrc): Don't bother killing off '\r' since
3403 pars_line() skips whitespace at end of line anyway.
3404 (parse_line): Oops, it didn't. Now it does.
3406 * recur.c (parse_robots): Ditto here.
3408 * ftp-ls.c (ftp_parse_unix_ls): Kill off the newline character
3409 manually because read_whole_line no longer does.
3411 * utils.c (read_whole_line): Rewrite to: a) use less memory
3412 (reallocates to needed size after work), b) work faster -->
3413 fgets() instead of getc, c) be more correct --> doesn't kill the
3414 newline character at the end of line.
3416 2000-11-10 Hrvoje Niksic <hniksic@arsdigita.com>
3418 * init.c (comind): Initialize MAX to array size - 1.
3420 2000-11-08 Hrvoje Niksic <hniksic@arsdigita.com>
3422 * url.c (construct): Changed last_slash[-1] to *(last_slash - 1).
3423 Suggested by Edward J. Sabol.
3425 2000-11-08 Hrvoje Niksic <hniksic@arsdigita.com>
3427 * url.c (construct): Handle the case where host name is not
3428 followed by a slash.
3430 2000-11-06 Hrvoje Niksic <hniksic@arsdigita.com>
3432 * init.c: commands[] need to be sorted! ("base" wasn't.)
3434 2000-11-05 Hrvoje Niksic <hniksic@arsdigita.com>
3436 * wget.h (DO_REALLOC_FROM_ALLOCA): Use braces to disambiguate
3439 2000-11-05 Hrvoje Niksic <hniksic@arsdigita.com>
3441 * url.c (construct): Insert unneeded initialization for the
3442 compiler to shut up.
3444 * config.h.in: Define _XOPEN_SOURCE to 500 to get the prototype
3445 for strptime() (*duh*). Define _SVID_SOURCE to get S_IFLNK which
3446 otherwise gets lost when you define _XOPEN_SOURCE.
3448 * utils.c (touch): Include the file name in the error message.
3451 2000-11-05 Hrvoje Niksic <hniksic@arsdigita.com>
3453 * log.c (logvprintf): Use vsnprintf() in all cases. If necessary,
3454 resize the buffer to fit the formated message. That way, messages
3455 of arbitrary size may be printed.
3456 (logvprintf): Use saved_append() to optionally log the last
3457 several lines of output.
3459 (log_close): Adapt to new data structures.
3461 (redirect_output): Print messages to stderr, not to stdout.
3463 * log.c (saved_append_1): New function. Replaces the old logging
3464 system ("log all output until 10M characters") with a new, much
3465 more reasonable one ("log last screenful of text").
3466 (saved_append): New function; call saved_append_1.
3467 (free_log_line): New function.
3469 2000-11-05 Hrvoje Niksic <hniksic@arsdigita.com>
3471 * url.c (construct): Fix comment.
3472 (find_last_char): Document.
3474 2000-11-04 Hrvoje Niksic <hniksic@arsdigita.com>
3476 * snprintf.c: New file.
3478 2000-11-03 Hrvoje Niksic <hniksic@arsdigita.com>
3480 * wget.h: If HAVE_STDARG_H is not defined, don't declare argument
3481 types to logprintf() and debug_logprintf().
3483 2000-11-02 Hrvoje Niksic <hniksic@arsdigita.com>
3485 * ftp.c (ftp_loop_internal): Hide the password from the URL when
3486 printing non-verbose. Problem spotted by Dariusz Mlynarczyk
3487 <darekm@bydg.lomac.com.pl>.
3489 2000-11-02 Junio Hamano <junio@twinsun.com>
3491 * ftp-basic.c (ftp_login): Make comparison case-insensitive.
3493 2000-11-02 Tyler Riddle <triddle@liquidmarket.com>
3495 * http.c (known_authentication_scheme_p): Recognize NTML
3497 (create_authorization_line): Treat NTML the same as `Basic'.
3499 2000-11-02 Hrvoje Niksic <hniksic@arsdigita.com>
3501 * retr.c (retrieve_url): Free url before returning.
3502 (retrieve_url): Free mynewloc before returning.
3503 Spotted by Mark A. Mankins <Mankins_Mark@prc.com>.
3505 2000-11-02 Hrvoje Niksic <hniksic@arsdigita.com>
3507 * url.c (parseurl): Remove possible reading past the end of
3508 sup_protos[]. Spotted by Mark A. Mankins <Mankins_Mark@prc.com>.
3510 2000-11-01 Hrvoje Niksic <hniksic@arsdigita.com>
3512 * main.c (main): In case of opt.downloaded overflowing, print
3513 <overflow> instead of a totally bogus random value.
3515 * retr.c (retrieve_from_file): Ditto.
3517 * recur.c (recursive_retrieve): Ditto.
3519 * main.c (main): Ditto.
3521 * http.c (http_loop): Ditto.
3523 * ftp.c (ftp_loop_internal): Use downloaded_increase() instead of
3524 `+=', and downloaded_exceeds_quota() instead of the simple-minded
3526 (ftp_retrieve_list): Ditto.
3527 (ftp_retrieve_dirs): Ditto.
3528 (ftp_retrieve_glob): Ditto.
3530 * retr.c (downloaded_increase): New function. Notice overflows of
3532 (downloaded_exceeds_quota): Make sure that opt.downloaded is not
3533 used if it overflowed.
3535 * options.h (struct options): New member downloaded_overflow.
3537 2000-11-01 Hrvoje Niksic <hniksic@arsdigita.com>
3539 * wget.h (enum): Remove extra space after last enumeration.
3541 2000-11-01 Hrvoje Niksic <hniksic@arsdigita.com>
3543 * main.c (main): Use legible_very_long() for printing
3546 * utils.c (legible_1): New function that operates on strings and
3547 does the brunt of legible()'s work.
3548 (legible): Use legible_1().
3549 (legible_very_long): New function; dump the argument with
3550 sprintf(), and call legible_1().
3552 * options.h (struct options): Use VERY_LONG_TYPE for
3555 * sysdep.h (VERY_LONG_TYPE): Define it to have a 64-bit or greater
3558 * config.h.in: Make sure that SIZEOF_LONG and SIZEOF_LONG_LONG get
3559 defined. Define HAVE_LONG_LONG if long long is available.
3561 2000-11-01 Hrvoje Niksic <hniksic@arsdigita.com>
3563 * utils.c (long_to_string): Update with a later, better version.
3565 2000-11-01 Hrvoje Niksic <hniksic@arsdigita.com>
3567 * url.c (path_simplify_with_kludge): New function.
3568 (path_simplify_with_kludge): Disable it. Instead...
3569 (parse_dir): ...make sure that at this point the right thing is
3570 done, i.e. that "query" part of the URL (?...) is always assigned
3571 to the file, never to the directory portion of the path.
3573 2000-11-01 Hrvoje Niksic <hniksic@arsdigita.com>
3575 * retr.c (retrieve_url): Detect redirection cycles.
3577 2000-11-01 Hrvoje Niksic <hniksic@arsdigita.com>
3579 * url.c (get_urls_html): Decode HTML entities using
3580 html_decode_entities.
3582 * html.c (htmlfindurl): Don't count the `#' in numeric entities
3583 (&#NNN;) as an HTML fragemnt.
3584 (html_decode_entities): New function.
3586 2000-11-01 Hrvoje Niksic <hniksic@arsdigita.com>
3588 * html.c (htmlfindurl): Fix recognition of # HTML fragments.
3590 2000-11-01 Hrvoje Niksic <hniksic@arsdigita.com>
3592 * url.c (construct): Rewritten for clarity. Avoids the
3593 unnecessary copying and stack-allocation the old version
3596 2000-10-31 Hrvoje Niksic <hniksic@arsdigita.com>
3598 * ftp.c (getftp): Ditto.
3600 * http.c (gethttp): Rewind the stream when retrying from scratch.
3602 2000-10-31 Hrvoje Niksic <hniksic@arsdigita.com>
3604 * retr.c (retrieve_url): Use url_concat() to handle relative
3605 redirections instead of /ad hoc/ code.
3607 * url.c (url_concat): New function encapsulating weird
3609 (urllen_http_hack): New function.
3610 (construct): When constructing new URLs, recognize that `?' does
3611 not form part of the file name in HTTP.
3613 2000-10-13 Adrian Aichner <adrian@xemacs.org>
3615 * retr.c: Add msec timing support for WINDOWS.
3616 * retr.c (reset_timer): GetSystemTime() on WINDOWS.
3617 * retr.c (elapsed_time): Calculate delta time to msec on WINDOWS.
3619 2000-10-27 Dan Harkless <wget@harkless.org>
3621 * retr.c (retrieve_url): Manually applied T. Bharath
3622 <TBharath@responsenetworks.com>'s patch to get wget to grok
3623 illegal relative URL redirects. Reformatted and re-commented it.
3625 2000-10-23 Dan Harkless <wget@harkless.org>
3627 * connect.c (make_connection and bindport): Manually applied Rob
3628 Mayoff <mayoff@dqd.com>'s 1.5.3 patch to add --bind-address,
3629 changing coding style to GNU's.
3631 * ftp.c (ftp_loop_internal): --delete-after wasn't implemented for
3632 files downloaded via FTP. Per a comment, .listing files were not
3633 counted towards number of bytes and files downloaded because they're
3634 deleted anyway. Well, they aren't under -nr, so count them then.
3636 * init.c: Manually applied Rob Mayoff's 1.5.3 patch to add
3637 --bind-address, alphabetizing, changing coding style to GNU's,
3638 commenting, and renaming cmd_ip_address() to cmd_address() to
3639 imply hostnames also okay.
3641 * main.c (main): --delete-after didn't delete the root of the
3642 tree. Ignore --convert-links if --delete-after was specified.
3643 Manually applied Rob Mayoff's 1.5.3 patch to add --bind-address,
3644 fixing duplicate use of added-since-1.5.3 case value.
3645 (print_help): Clarified that --delete-after deletes local files.
3646 Rob forgot to add a line for his new --bind-address option.
3648 * options.h (struct options): Manually applied Rob Mayoff's patch
3649 to add --bind-address (bind_address structure member).
3651 * recur.c (recursive_retrieve): Improved comment; added DEBUGP().
3652 Ignore --convert-links if --delete-after was specified.
3654 * retr.c (retrieve_from_file): Just added a DEBUGP().
3656 2000-10-19 Dan Harkless <wget@harkless.org>
3658 * ftp.c (ftp_loop_internal): downloaded_file() enumerators changed.
3659 (getftp): Applied Piotr Sulecki <Piotr.Sulecki@ios.krakow.pl>'s
3660 patch to work around FTP servers that incorrectly respond to the
3661 "REST" command with the remaining size rather than the total file size.
3663 * http.c (gethttp): Improved a comment and added code to tack on
3664 ".html" to text/html files without that extension when -E specified.
3665 (http_loop): Use new downloaded_file() enumerators and deal with
3666 the case of gethttp() called xrealloc() on u->local.
3668 * init.c (commands): Added new "htmlextension" command.
3669 Also renamed John Daily's cmd_quad() to the more descriptive
3670 cmd_lockable_boolean(), alpha-sorted the CMD_DECLARE()s and
3671 removed duplicate cmd_boolean() declaration.
3673 * main.c (print_help): Added my new -E / --html-extension option.
3674 (main): Undocumented --email-address option previously used -E synonym.
3675 Stole it away for the much more deserving --html-extension's use.
3677 * options.h (struct options): Added html_extension field.
3679 * url.c (convert_links): URL X that we saved as X.html locally due
3680 to -E needs to be backed up as X.orig, not X.html.orig. Added comments.
3681 (downloaded_file): Now remembers if we added .html extension to a file.
3683 * url.h (downloaded_file_t): Added extra enumerators to support above.
3684 (downloaded_file): Now takes and returns a downloaded_file_t.
3686 * wget.h (unnamed "dt" enum): Added ADDED_HTML_EXTENSION enumerator.
3688 2000-10-09 Dan Harkless <wget@harkless.org>
3690 * html.c (htmlfindurl): Added unneeded initialization to quiet warning.
3692 * main.c (print_help): Clarified what --retr-symlinks does.
3694 2000-09-15 John Daily <jdaily@cyberdude.com>
3696 * init.c: Add support for "always" and "never" values to allow
3697 .wgetrc to override commandline (useful e.g. with .pm files
3698 calling `wget --passive-ftp' when your firewall doesn't allow that).
3700 * ftp.c (getftp): passive_ftp is first option to support always/never.
3702 2000-08-30 Dan Harkless <wget@harkless.org>
3704 * ftp.c (ftp_retrieve_list): Use new INFINITE_RECURSION #define.
3706 * html.c: htmlfindurl() now takes final `dash_p_leaf_HTML' parameter.
3707 Wrapped some > 80-column lines. When -p is specified and we're at a
3708 leaf node, do not traverse <A>, <AREA>, or <LINK> tags other than
3709 <LINK REL="stylesheet">.
3711 * html.h (htmlfindurl): Now takes final `dash_p_leaf_HTML' parameter.
3713 * init.c: Added new -p / --page-requisites / page_requisites option.
3715 * main.c (print_help): Clarified that -l inf and -l 0 both allow
3716 infinite recursion. Changed the unhelpful --mirrior description
3717 to simply give the options it's equivalent to. Added new -p option.
3718 (main): Added some comments; handle new -p / --page-requisites.
3720 * options.h (struct options): Added new page_requisites field.
3722 * recur.c: Changed "URL-s" to "URLs" and "HTML-s" to "HTMLs".
3723 Calculate and pass down new `dash_p_leaf_HTML' parameter to
3724 get_urls_html(). Use new INFINITE_RECURSION #define.
3726 * retr.c: Changed "URL-s" to "URLs". get_urls_html() now takes
3727 final `dash_p_leaf_HTML' parameter.
3729 * url.c: get_urls_html() and htmlfindurl() now take final
3730 `dash_p_leaf_HTML' parameter.
3732 * url.h (get_urls_html): Now takes final `dash_p_leaf_HTML' parameter.
3734 * wget.h: Added some comments and new INFINITE_RECURSION #define.
3736 2000-08-23 Dan Harkless <wget@harkless.org>
3738 * main.c (print_help): -B / --base was not mentioned.
3740 2000-08-22 Dan Harkless <wget@harkless.org>
3742 * main.c (print_help): Modified -nc description to mention that it
3743 also prevents the creation of multiple versions of the same file
3744 with ".<number>" suffixes.
3746 2000-07-14 Jan Prikryl <prikryl@cg.tuwien.ac.at>
3748 * retr.c (retrieve_url): Consistently strdup opt.referer when
3751 2000-06-09 Dan Harkless <wget@harkless.org>
3753 * main.c (print_help): --help output for --waitretry was over 80 cols.
3755 2000-06-09 Hrvoje Niksic <hniksic@iskon.hr>
3757 * url.c (encode_string): Fix comment.
3758 Suggested by Herold Heiko <Heiko.Herold@previnet.it>.
3760 2000-06-01 Const Kaplinsky <const@ce.cctpu.edu.ru>
3762 * ftp.c (ftp_retrieve_list): Change permissions only on plain
3765 2000-06-01 Hrvoje Niksic <hniksic@iskon.hr>
3767 * url.c (str_url): Print the port number only if it's different
3768 from the default port number for that protocol.
3770 2000-05-22 Dan Harkless <wget@harkless.org>
3772 * main.c (print_help): Added --help line for Damir Dzeko
3773 <ddzeko@zesoi.fer.hr>'s until-now-undocumented --referer option.
3774 Removed comments that --referer and --waitretry were undocumented.
3775 Changed "`.wgetrc' command" to "`.wgetrc'-style command" on --help
3778 2000-05-18 Hrvoje Niksic <hniksic@iskon.hr>
3780 * ftp.c (getftp): Ditto.
3782 * http.c (gethttp): Check for return value of fclose/fflush.
3784 2000-04-12 Hrvoje Niksic <hniksic@iskon.hr>
3786 * host.c (store_hostaddress): Instead of shifting ADDR, start
3787 copying from the correct address.
3789 2000-04-12 Hrvoje Niksic <hniksic@iskon.hr>
3791 * http.c (gethttp): Don't free REQUEST -- it was allocated with
3793 Pointed out by Gisle Vanem <gvanem@eunet.no>.
3795 2000-04-04 Dan Harkless <wget@harkless.org>
3797 * host.c (store_hostaddress): R. K. Owen's patch introduces a
3798 "left shift count >= width of type" warning on 32-bit
3799 architectures. Got rid of it by tricking the compiler w/ a variable.
3801 * url.c (UNSAFE_CHAR): The macro didn't include all the illegal
3802 characters per RFC1738, namely everything above '~'. It also
3803 generated a warning on OSes where char =~ unsigned char. Fixed.
3805 1998-10-17 Hrvoje Niksic <hniksic@srce.hr>
3807 * http.c (http_process_type): Removed needless strdup(), a memory
3810 1998-09-25 Hrvoje Niksic <hniksic@srce.hr>
3812 * html.c (htmlfindurl): Set PH to the first occurrence of `#'.
3814 1998-09-25 Simon Munton <simonm@m4data.co.uk>
3816 * init.c (wgetrc_file_name): Don't free HOME under Windows.
3818 1998-12-01 "R. K. Owen" <rkowen@Nersc.GOV>
3820 * host.c (store_hostaddress): Fix for big endian 64-bit machines.
3822 1998-12-01 Hrvoje Niksic <hniksic@srce.hr>
3824 * url.c (UNSAFE_CHAR): New macro.
3825 (contains_unsafe): Use it.
3826 (encode_string): Ditto.
3828 1998-12-01 Hrvoje Niksic <hniksic@srce.hr>
3830 * main.c (i18n_initialize): Use LC_MESSAGES only if available.
3832 2000-03-31 Hrvoje Niksic <hniksic@srce.hr>
3834 * Use TOUPPER/TOLOWER.
3836 1998-12-22 Alexander V. Lukyanov <lav@yars.free.net>
3838 * ftp-opie.c (btoe): Zero-terminate OSTORE.
3840 2000-03-21 Hrvoje Niksic <hniksic@iskon.hr>
3842 * wget.h (DO_REALLOC_FROM_ALLOCA): Ditto.
3844 * sysdep.h (ISALNUM): New macro.
3848 2000-03-10 Dan Harkless <wget@harkless.org>
3850 * html.c (idmatch): Implemented checking of my new --follow-tags
3851 and --ignore-tags options.
3853 * init.c (commands): Added comment reminding people adding new
3854 entries doing allocation to add corresponding freeing in cleanup().
3855 (commands): Added new followtags and ignoretags commands.
3856 (cleanup): Free storage for new followtags and ignoretags.
3858 * main.c: Use of "comma-separated list" was random -- normalized
3859 it. Did some alphabetization. Added comments pointing out
3860 "Options without arguments" and "Options accepting an argument"
3861 sections of long_options[]. Added new options --follow-tags and
3862 -G / --ignore-tags. Added comment that Damir's --referer is
3863 currently undocumented. Added comment that Heiko's --waitretry is
3864 partially undocumented (mentioned in --help but not in
3865 wget.texi). Moved improperly sorted 24, 129, and 'G' cases.
3867 * options.h (struct options): Added new fields follow_tags and
3870 * wget.h: Added "#define EQ 0" so we can say "strcmp(a, b) == EQ".
3872 2000-03-02 Dan Harkless <wget@harkless.org>
3874 * ftp.c (ftp_loop_internal): Heiko introduced "suggest explicit
3875 braces to avoid ambiguous `else'" warnings. Eliminated them.
3877 * http.c (gethttp): Dan Berger's query string patch is totally
3878 bogus. If you have two different URLs, gen_page.cgi?page1 and
3879 get_page.cgi?page2, they'll both be saved as get_page.cgi and the
3880 second will overwrite the first. Also, parameters to implicit
3881 CGIs, like "http://www.host.com/db/?2000-03-02" cause the URLs to
3882 be printed with trailing garbage characters, and could seg fault.
3883 Backing out the patch, which Dan B. informed me by email was just
3884 a kludge to download StarOffice from Sun made necessary due to
3885 wget's unconditional escaping of certain characters (room for an
3887 (http_loop): Heiko introduced "suggest explicit braces to avoid
3888 ambiguous `else'" warnings. Eliminated them.
3890 * main.c: Heiko's --wait / --waitretry backwards compatibility
3891 code looks to have been totally untested -- automatic variable
3892 'wr' was used without being initialized, and a long int was passed
3893 into setval()'s char* val parameter.
3895 * recur.c (parse_robots): Applied Edward J. Sabol
3896 <sabol@alderaan.gsfc.nasa.gov>'s patch for Guan Yang's reported
3897 problem with "User-agent:<space>*<space>" lines in robots.txt.
3899 * url.c (parseurl, str_url): Removing Dan Berger's code (see
3900 http.c above for explanation).
3902 1999-08-25 Heiko Herold <Heiko.Herold@previnet.it>
3904 * ftp.c: Respect new option waitretry.
3906 2000-01-30 Damir Dzeko <ddzeko@zesoi.fer.hr>
3908 * http.c (gethttp): Send custom Referer, if required.
3910 1999-09-24 Charles G Waldman <cgw@fnal.gov>
3912 * netrc.c (parse_netrc): Allow passwords to contain spaces.
3914 * netrc.c (parse_netrc): New function.
3916 1999-09-17 Dan Berger <dberger@ix.netcom.com>
3918 * http.c (gethttp): Send it.
3920 * url.c (parseurl): Detect query string in HTTP URL-s.
3921 (str_url): Print it.
3923 2000-03-02 HIROSE Masaaki <hirose31@t3.rim.or.jp>
3925 * html.c (html_allow): Add <link href=...> and <script src=...>.
3927 1999-05-02 andrew deryabin <djsf@softhome.net>
3929 * http.c (gethttp): Specify port in `Host' header only if it's
3932 1998-11-03 Edward J. Sabol <sabol@alderaan.gsfc.nasa.gov>
3934 * recur.c (recursive_retrieve): If a finite maximum depth is
3935 specified, and we're are already at that depth, don't download the
3936 HTML file for parsing.
3938 2000-03-01 Dan Harkless <wget@harkless.org>
3940 * ftp.c (ftp_loop_internal): Call new downloaded_file() function,
3941 even though we don't do conversion on HTML files retrieved via
3942 FTP, so _current_ usage of downloaded_file() makes this call unneeded.
3943 (ftp_retrieve_list): Added a comment saying where we need to
3944 stat() a .orig file if FTP'd HTML file conversion is ever implemented.
3945 (ftp_retrieve_list): "Local file '%s' is more recent," is sometimes
3946 a lie -- reworded as "Server file no newer than local file '%s' --".
3948 * http.c (http_loop): Fixed a typo and clarified a comment.
3949 (http_loop): When -K and -N are specified together, compare size
3950 and timestamp of server file X against local file X.orig (if
3951 extant) rather than converted local file X.
3952 (http_loop): "Local file '%s' is more recent," is sometimes a lie
3953 -- reworded as "Server file no newer than local file '%s' --".
3954 (http_loop): Call new downloaded_file() function to prevent
3955 wrongful overwriting of .orig file when -N is specified.
3957 * url.c (convert_links): When -K specified, only rename X to
3958 X.orig if downloaded_file() returns TRUE. Otherwise when we skip
3959 file X due to -N, we clobber an X.orig from a previous invocation.
3960 (convert_links): Call the failsafe xstrdup(), not the real strdup().
3961 (convert_links): Added a note asking anyone who understands how
3962 multiple URLs can correspond to a single file to comment it.
3963 (downloaded_file): Added this new function.
3965 * url.h (downloaded_file): Added prototype for this new function
3966 as well as its downloaded_file_t enum type.
3968 * wget.h (boolean): Added this new typedef and TRUE and FALSE #defines.
3970 2000-02-29 Dan Harkless <wget@harkless.org>
3972 * version.c: Upped version to developer-only "1.5.3+dev".
3974 2000-02-18 Dan Harkless <wget@harkless.org>
3976 * init.c (backup_converted): Added this new option.
3978 * main.c (-K / --backup-converted): Added this new option.
3980 * options.h (backup_converted): Added this new option.
3982 * url.c (convert_links): When backup_converted is specified, save
3983 file X as X.orig before converting.
3985 * url.h (urlpos): Fixed typo -- said "Rekative" instead of "Relative".
3987 1998-09-21 Hrvoje Niksic <hniksic@srce.hr>
3989 * version.c: Wget 1.5.3 is released.
3991 1998-09-21 Hrvoje Niksic <hniksic@srce.hr>
3993 * host.c (ftp_getaddress): Don't warn when reverse-lookup of local
3994 address doesn't yield FQDN.
3996 1998-09-21 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
3998 * cmpt.c (strerror): Fix declaration of sys_errlist.
4000 1998-09-11 Hrvoje Niksic <hniksic@srce.hr>
4002 * main.c (main): Don't use an array subscript as the first
4003 argument to STRDUP_ALLOCA.
4004 From Kaveh R. Ghazi.
4006 1998-09-11 Szakacsits Szabolcs <szaka@sienet.hu>
4008 * html.c (htmlfindurl): Download table background.
4010 1998-09-11 Hans Grobler <grobh@conde.ee.sun.ac.za>
4012 * init.c (parse_line): Would free *com before allocating it.
4013 (parse_line): Would free com instead of *com.
4015 1998-09-10 Howard Gayle <howard@fjst.com>
4017 * url.c (get_urls_html): Would drop the last character of the
4020 1998-09-10 Hrvoje Niksic <hniksic@srce.hr>
4022 * http.c (http_loop): Don't print status code if quiet.
4024 1998-09-10 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
4026 * log.c: Use <stdarg.h> only when __STDC__.
4028 1998-09-10 Adam D. Moss <adam@foxbox.org>
4030 * html.c (htmlfindurl): Download <layer src=...>.
4032 1998-09-10 Howard Gayle <howard@fjst.com>
4034 * ftp.c (ftp_retrieve_list): Don't update the time stamp of a file
4037 1998-06-27 Hrvoje Niksic <hniksic@srce.hr>
4039 * utils.c: Include <libc.h> on NeXT.
4041 1998-06-26 Heinz Salzmann <heinz.salzmann@intermetall.de>
4043 * url.c (get_urls_html): Fix calculation of URL position.
4045 1998-06-23 Hrvoje Niksic <hniksic@srce.hr>
4047 * version.c: Wget 1.5.2 is released.
4049 1998-06-23 Dave Love <d.love@dl.ac.uk>
4051 * ftp.c, init.c, netrc.c: Include errno.h.
4053 * http.c: Include errno.h and time header.
4055 * Makefile.in (exext): Define.
4056 (install.bin, uninstall.bin): Use it.
4058 1998-06-21 Hrvoje Niksic <hniksic@srce.hr>
4060 * http.c (http_loop): Don't attempt to compare local and remote
4061 sizes if the remote size is unknown.
4063 1998-06-16 Hrvoje Niksic <hniksic@srce.hr>
4065 * url.c (get_urls_html): Use malloc() instead of alloca in the
4068 1998-06-13 Hrvoje Niksic <hniksic@srce.hr>
4070 * version.c: Wget 1.5.2-b4 is released.
4072 1998-06-13 Hrvoje Niksic <hniksic@srce.hr>
4074 * url.c (get_urls_html): Ignore spaces before and after the URI.
4076 1998-06-08 Wanderlei Antonio Cavassin <cavassin@conectiva.com.br>
4078 * ftp.c (getftp): Translate `done'.
4080 1998-06-06 Hrvoje Niksic <hniksic@srce.hr>
4082 * version.c: Wget 1.5.2-b3 is released.
4084 1998-06-06 Alexander Kourakos <awk@bnt.com>
4086 * init.c (cleanup): Close dfp, don't free it.
4088 1998-06-06 Hrvoje Niksic <hniksic@srce.hr>
4090 * utils.c (make_directory): Twiddle.
4092 * config.h.in: Added template for access().
4094 1998-06-05 Mathieu Guillaume <mat@cythere.com>
4096 * html.c (htmlfindurl): Download <input src=...>
4098 1998-06-03 Hrvoje Niksic <hniksic@srce.hr>
4100 * utils.c (file_exists_p): Use access() with two arguments.
4102 1998-05-27 Martin Kraemer <Martin.Kraemer@mch.sni.de>
4104 * netrc.c (parse_netrc): Correct logic.
4106 1998-05-27 Hrvoje Niksic <hniksic@srce.hr>
4108 * ftp.c (getftp): Added `break'; suggested by Lin Zhe Min
4109 <ljm@ljm.wownet.net>.
4111 1998-05-24 Hrvoje Niksic <hniksic@srce.hr>
4113 * version.c: Wget 1.5.2-b2 is released.
4115 1998-05-18 Juan Jose Rodriguez <jcnsoft@jal1.telmex.net.mx>
4117 * mswindows.h: Don't translate mkdir to _mkdir under Borland.
4119 1998-05-17 Hrvoje Niksic <hniksic@srce.hr>
4121 * retr.c (elapsed_time): Return correct value when
4122 HAVE_GETTIMEOFDAY is undefined.
4124 1998-05-13 Hrvoje Niksic <hniksic@srce.hr>
4126 * version.c: Wget 1.5.2-b1 is released.
4128 1998-05-08 Hrvoje Niksic <hniksic@srce.hr>
4130 * getopt.c (_getopt_internal): Use exec_name instead of argv[0].
4131 (_getopt_internal): Don't translate `#if 0'-ed strings.
4133 1998-05-06 Douglas E. Wegscheid <wegscd@whirlpool.com>
4135 * mswindows.c (ws_handler): Use fork_to_background().
4137 1998-05-05 Hrvoje Niksic <hniksic@srce.hr>
4139 * version.c: Wget 1.5.1 is released.
4141 1998-05-05 Hrvoje Niksic <hniksic@srce.hr>
4143 * http.c (parse_http_status_line): Avoid `minor' and `major'
4146 1998-05-02 Hrvoje Niksic <hniksic@srce.hr>
4148 * utils.c (mkdirhier): Renamed to make_directory.
4150 1998-05-01 Hrvoje Niksic <hniksic@srce.hr>
4152 * mswindows.c (fork_to_background): Define under Windows.
4154 * utils.c (fork_to_background): New function.
4156 * html.c (htmlfindurl): Removed rerdundant casts.
4158 1998-05-01 Douglas E. Wegscheid <wegscd@whirlpool.com>
4160 * mswindows.c (ws_mypath): Cache the path.
4162 1998-04-30 Douglas E. Wegscheid <wegscd@whirlpool.com>
4164 * ftp.h: Prefix enum ftype members with FT_.
4166 * ftp-ls.c, ftp.c, html.h: Adjust accordingly.
4168 * mswindows.h: Use stat under Borland, _stat under MSVC.
4170 1998-04-28 Hrvoje Niksic <hniksic@srce.hr>
4172 * http.c (known_authentication_scheme_p): New function.
4173 (gethttp): Handle authorization more correctly.
4175 * ftp-basic.h: Removed.
4179 * utils.c: Include <unistd.h> before <pwd.h>; needed under SunOS
4181 (numdigit): Use `while' loop.
4183 * http.c (create_authorization_line): Detect authentication
4184 schemes case-insensitively.
4186 * http.c (extract_header_attr): Use strdupdelim().
4187 (digest_authentication_encode): Move declaration of local
4188 variables to smaller scope.
4189 (digest_authentication_encode): Reset REALM, OPAQUE and NONCE.
4190 (create_authorization_line): Detect authentication schemes
4193 * utils.c (touch): Constify.
4195 * http.c (gethttp): Report a nicer error when no data is received.
4197 * rbuf.h (RBUF_READCHAR): Ditto.
4199 * ftp-basic.c (ftp_response): Use sizeof.
4201 1998-04-27 Hrvoje Niksic <hniksic@srce.hr>
4203 * retr.c (print_percentage): EXPECTED is long, not int.
4204 (print_percentage): Use floating-point arithmetic to avoid
4205 overflow with large files' sizes multiplied with 100.
4207 1998-04-27 Gregor Hoffleit <flight@mathi.uni-heidelberg.de>
4209 * config.h.in: Added pid_t stub.
4211 * sysdep.h (S_ISREG): Moved here from mswindows.h (NeXT doesn't
4214 1998-04-20 Hrvoje Niksic <hniksic@srce.hr>
4216 * version.c: Wget 1.5.0 is released.
4218 1998-04-18 Hrvoje Niksic <hniksic@srce.hr>
4220 * url.c (str_url): Ditto.
4222 * ftp-basic.c (ftp_rest): Use new name.
4224 * utils.c (long_to_string): Renamed from prnum().
4226 1998-04-16 Hrvoje Niksic <hniksic@srce.hr>
4228 * version.c: Wget 1.5-b17 is released.
4230 1998-04-08 Hrvoje Niksic <hniksic@srce.hr>
4232 * headers.c (header_get): New argument FLAGS.
4234 * http.c (gethttp): If request is malformed, bail out of the
4236 (gethttp): Check for empty header *after* the status line checks.
4237 (gethttp): Disallow continuations for status line.
4239 1998-04-08 Hrvoje Niksic <hniksic@srce.hr>
4241 * version.c: Wget 1.5-b16 is released.
4243 1998-04-08 Hrvoje Niksic <hniksic@srce.hr>
4245 * init.c (commands): Renamed `always_rest' to `continue'.
4247 1998-04-05 Hrvoje Niksic <hniksic@srce.hr>
4251 * log.c (logputs): New argument.
4252 (logvprintf): Ditto.
4255 1998-04-04 Hrvoje Niksic <hniksic@srce.hr>
4257 * http.c (http_atotm): Update comment.
4259 * main.c (i18n_initialize): Set LC_MESSAGES, not LC_ALL.
4261 * wget.h: Renamed ENABLED_NLS to HAVE_NLS.
4263 * main.c (i18n_initialize): New function.
4266 * log.c: Include <unistd.h>.
4268 * retr.c (show_progress): Cast alloca to char *.
4270 1998-04-04 Hrvoje Niksic <hniksic@srce.hr>
4272 * version.c: Wget 1.5-b15 is released.
4274 1998-04-04 Hrvoje Niksic <hniksic@srce.hr>
4276 * utils.h: Declare file_non_directory_p().
4278 1998-04-03 Hrvoje Niksic <hniksic@srce.hr>
4280 * main.c (main): It's `tries', not `numtries' now.
4282 1998-04-01 Hrvoje Niksic <hniksic@srce.hr>
4284 * init.c (getperms): Removed.
4286 1998-04-01 Tim Charron <tcharron@interlog.com>
4288 * log.c (logvprintf): Don't use ARGS twice.
4290 1998-04-01 John <john@futuresguide.com>
4292 * mswindows.c: Cleaned up.
4294 1998-04-01 Hrvoje Niksic <hniksic@srce.hr>
4296 * version.c: Wget 1.5-b14 is released.
4298 1998-04-01 Hrvoje Niksic <hniksic@srce.hr>
4300 * ftp-opie.c (STRLEN4): New macro.
4303 1998-04-01 Junio Hamano <junio@twinsun.com>
4305 * http.c: Document all the Digest functions.
4307 1998-04-01 Hrvoje Niksic <hniksic@srce.hr>
4309 * utils.c (file_non_directory_p): Renamed from isfile().
4311 * mswindows.h (S_ISREG): New macro, suggested by Tim Adam.
4313 1998-03-31 Hrvoje Niksic <hniksic@srce.hr>
4315 * utils.c (mkdirhier): Use 0777 instead of opt.dirmode.
4317 * init.c (cmd_spec_dotstyle): Use 48 dots per line for binary
4319 (cmd_permissions): Removed.
4321 * config.h.in: Add template for WORDS_BIGENDIAN.
4323 1998-03-31 Junio Hamano <junio@twinsun.com>
4325 * http.c (HEXD2asc): New macro.
4326 (dump_hash): Use it.
4328 1998-03-31 Hrvoje Niksic <hniksic@srce.hr>
4330 * version.c: Wget 1.5-b13 is released.
4332 1998-03-31 Hrvoje Niksic <hniksic@srce.hr>
4334 * main.c (main): Don't try to use `com'.
4336 1998-03-30 Hrvoje Niksic <hniksic@srce.hr>
4338 * init.c (cmd_permissions): New function.
4340 1998-03-30 Hrvoje Niksic <hniksic@srce.hr>
4342 * version.c: Wget 1.5-b12 is released.
4344 1998-03-30 Hrvoje Niksic <hniksic@srce.hr>
4346 * init.c (commands): Renamed `numtries' to `tries'.
4347 (cmd_spec_debug): Removed.
4348 (home_dir): Under Windows, return `C:\' if HOME is undefined.
4350 1998-03-29 Hrvoje Niksic <hniksic@srce.hr>
4352 * config.h.in: Define _XOPEN_SOURCE.
4354 * init.c (check_user_specified_header): New function.
4355 (cmd_spec_header): Use it.
4356 (cmd_spec_useragent): New function.
4358 1998-03-29 Hrvoje Niksic <hniksic@srce.hr>
4360 * version.c: Wget 1.5-b11 is released.
4362 1998-03-28 Hrvoje Niksic <hniksic@srce.hr>
4364 * wget.h: Include <libintl.h> only if NLS is enabled.
4366 1998-03-26 Hrvoje Niksic <hniksic@srce.hr>
4368 * options.h (struct options): Made `wait' a long.
4369 (struct options): Ditto for `timeout'.
4371 1998-03-19 Hrvoje Niksic <hniksic@srce.hr>
4373 * utils.c (exists): Renamed to file_exists_p.
4374 (file_exists_p): Use access() if available.
4376 1998-03-17 Hrvoje Niksic <hniksic@srce.hr>
4378 * utils.c (memfatal): Set save_log_p to 0 to avoid potential
4381 * log.c: do_logging -> save_log_p.
4383 * config.h.in: Added template for HAVE_VSNPRINTF.
4385 1998-03-16 Hrvoje Niksic <hniksic@srce.hr>
4389 * http.c: Protect declaration against non-ANSI compiler.
4391 * log.c (logvprintf): Use vsnprintf() if available.
4393 * getopt.c (main): Don't translate test stuff.
4395 1998-03-16 Hrvoje Niksic <hniksic@srce.hr>
4397 * version.c: Wget 1.5-b10 is released.
4399 1998-03-11 Hrvoje Niksic <hniksic@srce.hr>
4401 * ftp.c (getftp): Don't translate "CWD %s".
4403 * wget.h (GCC_FORMAT_ATTR): Renamed from FORMAT_ATTR.
4405 1998-03-07 Hrvoje Niksic <hniksic@srce.hr>
4407 * ftp-opie.c (btoe): Use memcpy() instead of strncat().
4409 * log.c (logputs): New function.
4410 (logvprintf): Renamed from vlogmsg; use logputs().
4412 * retr.c (show_progress): Print `[100%]' when the retrieval is
4415 * init.c (run_wgetrc): Use FILE, not PATH.
4416 (wgetrc_file_name): Ditto.
4418 1998-03-07 Tim Adam <tma@osa.com.au>
4420 * recur.c (parse_robots): Correctly reset `entries' on empty
4423 1998-03-07 Hrvoje Niksic <hniksic@srce.hr>
4425 * init.c (cmd_spec_debug): Use cmd_boolean().
4427 1998-02-23 Hrvoje Niksic <hniksic@srce.hr>
4429 * http.c (gethttp): Create proxy-authorization correctly.
4431 1998-02-22 Hrvoje Niksic <hniksic@srce.hr>
4435 * getopt.c: Use ANSI function definitions.
4437 * ftp-opie.c: New file.
4439 * options.h: Don't redefine EXTERN.
4441 * init.c: Sort it correctly.
4443 1998-02-22 Hrvoje Niksic <hniksic@srce.hr>
4445 * version.c: Wget 1.5-b9 is released.
4447 1998-02-22 Hrvoje Niksic <hniksic@srce.hr>
4449 * recur.c (recursive_retrieve): Reset `first_time'.
4451 * ftp.c (getftp): Added `default' clause to switches of uerr_t.
4453 * rbuf.c (rbuf_peek): Simplified.
4454 (rbuf_flush): Use MINVAL.
4456 * wget.h (MINVAL): Moved from url.h.
4458 * rbuf.h (RBUF_FD): New macro.
4460 * url.c (add_url): Add to the head of the list.
4462 * ftp.c (ftp_retrieve_list): Set the permissions to downloaded
4464 (getftp): Set the default permissions to 0600.
4466 1998-02-21 Hrvoje Niksic <hniksic@srce.hr>
4468 * url.c (get_urls_html): Ditto.
4469 (convert_links): Ditto.
4471 * recur.c (parse_robots): Ditto.
4473 * html.c (ftp_index): Ditto.
4475 * ftp-ls.c (ftp_parse_unix_ls): Open file as binary.
4477 * init.c (defaults): Initialize `opt' to zero via memset.
4479 * http.c (digest_authentication_encode): goto considered harmful.
4481 1998-02-19 Hrvoje Niksic <hniksic@srce.hr>
4483 * ftp.c (delelement): Simplify and fix leak.
4485 1998-02-18 Hrvoje Niksic <hniksic@srce.hr>
4487 * http.c (dump_hash): Use HEXD2ASC instead of home-grown stuff.
4489 * url.h (HEXD2ASC): Removed warning.
4491 * init.c (comind): Use binary search.
4492 (commands): Reorganized.
4494 (cmd_boolean): New function.
4495 (cmd_number): Ditto.
4496 (cmd_number_inf): Ditto.
4497 (cmd_string): Ditto.
4498 (cmd_vector): Ditto.
4499 (cmd_directory_vector): Ditto.
4502 (cmd_spec_debug): Ditto.
4503 (cmd_spec_dirmode): Ditto.
4504 (cmd_spec_dirstruct): Ditto.
4505 (cmd_spec_dotstyle): Ditto.
4506 (cmd_spec_header): Ditto.
4507 (cmd_spec_htmlify): Ditto.
4508 (cmd_spec_mirror): Ditto.
4509 (cmd_spec_outputdocument): Ditto.
4510 (cmd_spec_recursive): Ditto.
4511 (settime): Merged with cmd_time().
4512 (setbytes): Merged with cmd_bytes().
4513 (setonoff): Merged with cmd_boolean().
4516 1998-02-17 Hrvoje Niksic <hniksic@srce.hr>
4518 * Makefile.in (distclean): Remove `config.h'.
4520 1998-02-17 Hrvoje Niksic <hniksic@srce.hr>
4522 * version.c: Wget 1.5-b8 is released.
4524 1998-02-17 Hrvoje Niksic <hniksic@srce.hr>
4526 * http.c (digest_authentication_encode): New function.
4527 (create_authorization_line): Use it.
4528 (dump_hash): New function.
4529 (digest_authentication_encode): Use it.
4531 * fnmatch.c: Renamed from `mtch.c'.
4533 1998-02-15 Karl Eichwalder <ke@suse.de>
4535 * main.c (main): Tag "Written by..." string as translatable.
4537 1998-02-15 Hrvoje Niksic <hniksic@srce.hr>
4539 * wget.h (FREE_MAYBE): New macro.
4541 * http.c (create_authorization_line): Don't use ANSI C string
4542 concatenation feature.
4543 (basic_authentication_encode): Use alloca() for temporary
4552 * ftp-basic.c: Protect declaration against non-ANSI compiler.
4554 * http.c (create_authorization_line): Cast `unsigned char *' to
4555 `char *' for sprintf, to shut up the noisy Digital Unix cc.
4557 1998-02-15 Hrvoje Niksic <hniksic@srce.hr>
4559 * version.c: Wget 1.5-b7 is released.
4561 1998-02-15 Hrvoje Niksic <hniksic@srce.hr>
4563 * cmpt.c (strstr): Synched with glibc-2.0.6.
4565 * ftp-basic.c (calculate_skey_response): Ditto.
4566 (calculate_skey_response): Use alloca().
4568 * http.c (create_authorization_line): Work with FSF's version of
4571 * md5.c: New file, from GNU libc.
4573 1998-02-14 Hrvoje Niksic <hniksic@srce.hr>
4575 * url.h (URL_CLEANSE): Name the temporary variable more carefully.
4577 1998-02-13 Hrvoje Niksic <hniksic@srce.hr>
4579 * http.c (basic_authentication_encode): New function, instead of
4582 1998-02-13 Junio Hamano <junio@twinsun.com>
4584 * http.c: Add HTTP-DA support.
4585 * ftp-basic.c: Add Opie/S-key support.
4586 * config.h.in, Makefile.in: Add HTTP-DA and Opie/S-key support.
4587 * md5.c, md5.h: New files.
4589 1998-02-13 Hrvoje Niksic <hniksic@srce.hr>
4591 * http.c (http_process_range): Renamed from hprocrange().
4592 (http_process_range): Parse the whole header.
4594 * headers.c: New file.
4595 (header_process): New function.
4596 (header_get): Renamed from fetch_next_header.
4598 * all: Include utils.h only where necessary.
4600 * wget.h: Declare xmalloc(), xrealloc() and xstrdup() here.
4602 * wget.h: Add provisions for dmalloc.
4604 1998-02-12 Hrvoje Niksic <hniksic@srce.hr>
4606 * version.c: Wget 1.5-b6 is released.
4608 1998-02-12 Hrvoje Niksic <hniksic@srce.hr>
4610 * ftp.c (ftp_loop): Determine `filename' more precisely.
4612 * init.c (setval): Don't set `opt.quiet' if output-document is
4615 * log.c (log_init): Print to STDERR instead of STDOUT.
4616 (vlogmsg): Use STDERR by default.
4619 1998-02-11 Simon Josefsson <jas@pdc.kth.se>
4621 * host.c: Use addr_in again.
4623 1998-02-08 Karl Eichwalder <karl@suse.de>
4625 * http.c (gethttp): Fixed typo.
4627 1998-02-08 Hrvoje Niksic <hniksic@srce.hr>
4629 * version.c: Wget 1.5-b5 is released.
4631 1998-02-08 Hrvoje Niksic <hniksic@srce.hr>
4633 * retr.c (show_progress): Use it.
4635 * log.c (logflush): New function.
4637 * wget.h: Utilize __attribute__ if on gcc.
4639 1998-02-07 Hrvoje Niksic <hniksic@srce.hr>
4641 * http.c (base64_encode_line): New argument LENGTH.
4642 (BASIC_AUTHENTICATION_ENCODE): Use it.
4643 (BASIC_AUTHENTICATION_ENCODE): Take length of HEADER into account.
4645 * main.c (main): Fixed fprintf() format mismatch.
4647 1998-02-06 Hrvoje Niksic <hniksic@srce.hr>
4649 * version.c: Wget 1.5-b4 is released.
4651 1998-02-03 Simon Josefsson <jas@pdc.kth.se>
4653 * host.c: use sockaddr_in instead of addr_in.
4655 1998-02-04 Hrvoje Niksic <hniksic@srce.hr>
4657 * init.c (cleanup): Use it.
4659 * recur.c (recursive_cleanup): New function.
4661 * retr.c (retrieve_from_file): Ditto.
4663 * main.c (main): Use it.
4665 * recur.c (recursive_reset): New function.
4667 * retr.c (retrieve_from_file): Ditto.
4669 * main.c (main): Simplify call to recursive_retrieve().
4671 * recur.c (recursive_retrieve): Removed FLAGS argument.
4673 * http.c (gethttp): Changed call to iwrite().
4675 1998-02-03 Hrvoje Niksic <hniksic@srce.hr>
4677 * url.c (get_urls_html): Ditto.
4678 (free_urlpos): Ditto.
4682 * retr.c (retrieve_url): Move declaration of local variables to
4685 * url.c (urlproto): Use it.
4688 (get_urls_html): Ditto.
4690 * utils.h (ARRAY_SIZE): New macro.
4692 * url.c (proto): Moved from url.h.
4694 * url.h (URL_CLEANSE): Reformatted.
4695 (USE_PROXY_P): Renamed from USE_PROXY.
4697 * ftp-basic.c: Adjust to the new interface of iwrite().
4699 * ftp-basic.c (ftp_port): Use alloca().
4701 1998-02-03 Hrvoje Niksic <hniksic@srce.hr>
4703 * version.c: Wget 1.5-b3 is released.
4705 * host.c (ftp_getaddress): Don't print to stderr directly.
4707 * init.c (setbytes): Support `g' for gigabytes.
4708 (cmdtype): New specification CTIME.
4709 (setval): Use it with settime().
4710 (commands): Use it for WAIT and TIMEOUT.
4712 1998-02-02 Hrvoje Niksic <hniksic@srce.hr>
4714 * http.c (BASIC_AUTHENTICATION_ENCODE): New macro.
4717 * utils.c (unique_name_1): Moved from url.c.
4718 (unique_name): Ditto.
4720 * url.c (url_filename): Ditto.
4722 * log.c (redirect_output): Changed call to unique_name().
4724 * url.c (unique_name_1): Renamed from unique_name().
4725 (unique_name): Changed interface.
4727 * init.c (enum cmdid): Moved from init.h.
4729 (struct cmd): Ditto.
4731 * main.c (main): Use it.
4732 (main): Moved `--backups' to not have a short option.
4734 * options.h (struct options): New member BACKGROUND.
4736 * main.c (print_help): Rearranged.
4737 (main): New long options for -n* short options: --no-directories,
4738 --no-host-directories, --non-verbose, --no-host-lookup and
4739 --dont-remove-listing.
4741 1998-02-01 Hrvoje Niksic <hniksic@srce.hr>
4743 * main.c (main): Use log_close().
4745 * log.c: New variable LOGFP.
4747 (redirect_output): Don't open /dev/null; set LOGFP to stdin
4749 (log_close): New function.
4751 * options.h (struct options): Removed LFILE.
4753 * log.c (log_enable): Removed.
4755 * main.c (main): Use it.
4757 * log.c (log_init): New function.
4759 * url.c (get_urls_html): Removed needless assignment to BASE.
4761 * host.c (add_hlist): Don't set CMP needlessly.
4763 * utils.c (match_backwards): Ditto.
4764 (in_acclist): Ditto.
4766 * url.c (findurl): Ditto.
4768 * netrc.c (parse_netrc): Ditto.
4770 * log.c (log_dump): Ditto.
4772 * html.c (html_quote_string): Ditto.
4774 * ftp-basic.c (ftp_request): Made static.
4776 * connect.c: Made global variables static.
4778 * url.c (construct): Ditto.
4780 * init.c (init_path): Avoid assignment inside `if'-condition.
4782 * ftp.c: Don't include in.h or winsock.h.
4784 * ftp.c (ftp_loop): Use SZ.
4786 * connect.c (bindport): Cast &addrlen to int *.
4789 * init.c (initialize): Don't use SYSTEM_WGETRC unconditionally.
4791 1998-01-31 Hrvoje Niksic <hniksic@srce.hr>
4793 * ftp.c (getftp): Initialize opt.ftp_pass here.
4794 (ftp_retrieve_dirs): Use alloca().
4796 * init.c (defaults): Don't initialize opt.ftp_pass.
4798 * sysdep.h (S_ISLNK): Declare for OS/2; ditto for lstat.
4799 From Ivan F. Martinez <ivanfm@ecodigit.com.br>.
4801 1998-01-31 Hrvoje Niksic <hniksic@srce.hr>
4803 * recur.c (parse_robots): Check for comments more correctly.
4805 * host.c (ftp_getaddress): Use STRDUP_ALLOCA.
4806 (ftp_getaddress): Add diagnostics when reverse-lookup yields only
4809 1998-01-31 Hrvoje Niksic <hniksic@srce.hr>
4811 * version.c: Wget 1.5-b2 is released.
4813 * netrc.c (NETRC_FILE_NAME): Moved from netrc.h.
4815 * utils.c (proclist): Pass FNM_PATHNAME to fnmatch().
4817 * ftp-basic.c (ftp_pasv): Avoid unnecessary casting to unsigned
4820 * log.c: Don't attempt to hide arguments from ansi2knr.
4822 * cmpt.c: Synched strptime() and mktime() with glibc-2.0.6.
4824 * ansi2knr.c: Use a later version, from fileutils-3.16l alpha.
4826 * ftp.c (getftp): Ditto.
4828 * http.c (gethttp): Use it.
4830 * retr.c (get_contents): New argument EXPECTED; pass it to
4832 (show_progress): New argument EXPECTED; use it to display
4835 * init.c (setval): Ditto.
4837 * http.c (gethttp): Ditto.
4840 * ftp.c (getftp): Ditto.
4841 (ftp_loop_internal): Ditto.
4843 * ftp-ls.c (ftp_parse_unix_ls): Use abort() instead of assert(0).
4845 * sysdep.h (CLOSE): Simplify; use DEBUGP.
4847 * netrc.c (search_netrc): Use alloca().
4849 * init.c (defaults): Initialize no_flush.
4851 * log.c (vlogmsg): Don't flush if no_flush.
4853 * options.h (struct options): New variable no_flush.
4855 * main.c (main): Don't play games with buffering.
4857 * log.c (vlogmsg): Flush the output after every message.
4859 1998-01-31 Hrvoje Niksic <hniksic@srce.hr>
4861 * init.c (parse_line): Ditto.
4863 * url.c (get_urls_html): Ditto.
4865 * main.c (main): Don't cast to unsigned char.
4867 * init.c (run_wgetrc): Don't cast to unsigned char.
4868 (parse_line): Accept char instead of unsigned char.
4870 * html.c (htmlfindurl): Use char instead of unsigned char.
4874 * sysdep.h: Add wrappers to ctype macros to make them
4877 1998-01-30 Hrvoje Niksic <hniksic@srce.hr>
4879 * html.c (htmlfindurl): Download <img lowsrc=...>
4881 * main.c (main): Ignore SIGPIPE.
4883 * connect.c (select_fd): New argument WRITEP.
4884 (iwrite): Call select_fd().
4886 1997-02-27 Fila Kolodny <fila@ibi.com>
4888 * ftp.c (ftp_retrieve_list): If retrieving symlink and the proper
4889 one already exists, just skip it.
4891 1998-01-30 Hrvoje Niksic <hniksic@srce.hr>
4893 * http.c (gethttp): Cosmetic changes.
4895 * http.c (check_end): Allow `+D...' instead of `GMT'.
4896 From Fabrizio Pollastri <pollastri@cstv.to.cnr.it>.
4898 * url.c (process_ftp_type): New function.
4901 * connect.c (iwrite): Allow writing in a few chunks.
4902 (bindport): Made SRV static, so addr can point to it.
4903 (select_fd): Removed HPUX kludge.
4905 * host.c (free_hlist): Incorporated into clean_hosts().
4907 1998-01-29 Hrvoje Niksic <hniksic@srce.hr>
4909 * host.c (hlist): Made static.
4910 (search_address): Cosmetic change.
4912 1998-01-29 Hrvoje Niksic <hniksic@srce.hr>
4914 * version.c: Wget v1.5-b1 is released.
4916 * http.c (hgetlen): Use sizeof() to get the header length.
4919 (hgetlocation): Ditto.
4920 (hgetmodified): Ditto.
4921 (haccepts_none): Ditto.
4923 * main.c (main): Updated `--version' and `--help' output, as per
4924 Francois Pinard's suggestions.
4926 * main.c: Include locale.h; call setlocale(), bindtextdomain() and
4929 * config.h.in: Define stubs for I18N3.
4931 * wget.h: Include libintl.h.
4933 1998-01-28 Hrvoje Niksic <hniksic@srce.hr>
4935 * url.c (mkstruct): Check for opt.cut_dirs.
4936 (mkstruct): alloca()-te more, xmalloc() less.
4938 * utils.c (load_file): Check for ferror().
4940 * url.c (get_urls_file): Close only the files we opened.
4941 (get_urls_html): Ditto.
4942 (count_slashes): New function.
4946 * http.c (gethttp): Respect username and password provided by
4948 (base64_encode_line): Write into an existing buffer instead of
4949 malloc-ing a new one.
4950 (struct http_stat): Moved from http.h
4952 * retr.c (retrieve_url): Free SUF.
4954 * all: Removed lots of unnecessary .h dependencies.
4956 * html.c (global_state): Made static.
4958 * utils.h (ALLOCA_ARRAY): New macro.
4960 * main.c (main): New option `--cut-dirs'.
4962 * url.c (construct): Use alloca() for T.
4964 * utils.c (mkdirhier): Use STRDUP_ALLOCA.
4966 * host.c (_host_t): Moved from host.h.
4967 (struct host): Renamed from _host_t.
4968 (store_hostaddress): Use STRDUP_ALLOCA for INET_S.
4971 * host.h: Don't include url.h.
4973 * ftp.c (LIST_FILENAME): Moved from ftp.h.
4975 * init.c (DEFAULT_FTP_ACCT): Moved from ftp.h.
4977 * main.c (main): Enable log if the output goes to a TTY.
4979 * connect.h: Removed unused constant `BACKLOG'.
4981 * config.h.in: Check for isatty().
4983 * Makefile.in (LINK): Use CFLAGS when linking.
4985 1998-01-27 Hrvoje Niksic <hniksic@srce.hr>
4987 * mswindows.c (ws_hangup): Use redirect_output().
4989 * main.c (redirect_output_signal): New function; use
4992 * log.c (redirect_output): New function, based on hangup(), which
4995 * log.c (vlogmsg): New function.
4997 * wget.h (DEBUGP): Use debug_logmsg().
4999 * main.c (hangup): Use it.
5001 * log.c (log_dump): New function.
5003 * utils.h (DO_REALLOC): Use `long' for various sizes.
5005 * http.c (hskip_lws): Use `while', for clarity.
5006 (HTTP_DYNAMIC_LINE_BUFFER): New constant.
5007 (fetch_next_header): Use it instead of DYNAMIC_LINE_BUFFER.
5009 * ftp-basic.c (FTP_DYNAMIC_LINE_BUFFER): New constant.
5010 (ftp_response): Use it instead of DYNAMIC_LINE_BUFFER.
5012 * utils.c (DYNAMIC_LINE_BUFFER): Moved from utils.c.
5013 (LEGIBLE_SEPARATOR): Ditto.
5014 (FILE_BUFFER_SIZE): Ditto.
5016 * retr.c (BUFFER_SIZE): Moved from retr.h.
5019 (logmsg): Moved from utils.c.
5020 (debug_logmsg): New function.
5022 * mswindows.h: Include it here.
5026 * utils.c: Don't include <windows.h>.
5028 1998-01-25 Hrvoje Niksic <hniksic@srce.hr>
5030 * host.c (ftp_getaddress): Ditto.
5032 * main.c (main): Use it.
5034 * utils.h (STRDUP_ALLOCA): New macro.
5036 * init.c: Prepend `wget: ' to error messages printed on stderr.
5038 * utils.c (mkdirhier): Renamed from mymkdir.
5039 (touch): Renamed from my_touch.
5040 (pwd_cuserid): Renamed from my_cuserid().
5042 1998-01-24 Andy Eskilsson <andy.eskilsson@telelogic.se>
5044 * utils.c (accdir): Process wildcards.
5045 (proclist): New function.
5046 (accdir): Use it to avoid code repetition.
5048 1998-01-24 Hrvoje Niksic <hniksic@srce.hr>
5050 * recur.c (parse_robots): Respect opt.useragent; use alloca().
5052 * http.c (gethttp): Construct useragent accordingly.
5054 * version.c: Changed version string to numbers-only.
5056 * main.c (print_help): List all the options.
5058 * mswindows.c (windows_main_junk): Initialize argv0 here.
5060 1998-01-24 Karl Heuer <kwzh@gnu.org>
5062 * netrc.c (search_netrc): Initialize `l' only after processing
5065 * main.c (main): Don't trap SIGHUP if it's being ignored.
5067 1998-01-24 Hrvoje Niksic <hniksic@srce.hr>
5069 * all: Use logmsg().
5071 * utils.c (time_str): Moved from retr.c.
5072 (logmsg): New function.
5073 (logmsg_noflush): Ditto.
5075 * rbuf.c: New file, moved buf_* functions here.
5077 * ftp.c (ftp_expected_bytes): Moved from ftp-basic.c.
5079 * ftp-basic.c (ftp_rest): Use prnum().
5081 * ftp-basic.c: Ditto.
5083 * ftp.c: Use the new reading functions and macros.
5085 * retr.c (buf_initialize): New function.
5086 (buf_initialized_p): Ditto.
5087 (buf_uninitialize): Ditto.
5090 * http.c (fetch_next_header): Use the BUF_READCHAR macro for
5092 (gethttp): Use alloca() where appropriate.
5094 * retr.c (buf_readchar): Use it.
5095 (buf_peek): Use rstreams.
5097 * retr.h (BUF_READCHAR): New macro.
5099 * init.c (home_dir): Rewritten for clarity.
5102 * mswindows.c (ws_backgnd): Made static.
5103 (read_registry): Ditto.
5104 (ws_cleanup): Ditto.
5105 (ws_handler): Ditto.
5107 1998-01-23 Hrvoje Niksic <hniksic@srce.hr>
5109 * alloca.c: New file.
5111 * Makefile.in (ALLOCA): Define.
5113 * mswindows.c (ws_help): Constify.
5114 (ws_help): Use alloca.
5116 * mswindows.c: Reformat.
5118 * all: Added _(...) annotations for I18N snarfing and translation.
5120 * host.c (ftp_getaddress): Nuke SYSINFO.
5121 (ftp_getaddress): Don't use getdomainname().
5122 (ftp_getaddress): Use uname(), where available.
5124 * http.c (gethttp): Protect a stray fprintf().
5126 * init.c (settime): New function.
5127 (setval): Treat WAIT specially, allowing suffixes like `m' for
5130 1998-01-21 Hrvoje Niksic <hniksic@srce.hr>
5132 * url.c (get_urls_html): Use alloca() for TEMP.
5134 1998-01-21 Jordan Mendelson <jordy@wserv.com>
5136 * url.c (rotate_backups): New function.
5138 * http.c (gethttp): Ditto.
5140 * ftp.c (getftp): Rotate backups.
5142 1997-12-18 Hrvoje Niksic <hniksic@srce.hr>
5144 * all: Renamed nmalloc(), nrealloc() and nstrdup() to xmalloc(),
5145 xrealloc() and xstrdup(). Use the new functions.
5147 * url.c (decode_string): Made static.
5150 (parse_uname): Ditto.
5153 (construct_relative): Ditto.
5155 * retr.c (show_progress): Made static.
5157 * recur.c (robots_url): Made static.
5158 (retrieve_robots): Ditto.
5159 (parse_robots): Ditto.
5160 (robots_match): Ditto.
5164 * main.c (printhelp): Made static.
5167 * init.c (comind): Made static.
5170 (run_wgetrc): Ditto.
5178 * http.c (fetch_next_header): Made static.
5179 (hparsestatline): Ditto.
5184 (hgetlocation): Ditto.
5185 (hgetmodified): Ditto.
5186 (haccepts_none): Ditto.
5188 (base64_encode_line): Ditto.
5189 (mktime_from_utc): Ditto.
5190 (http_atotm): Ditto.
5192 * html.c (idmatch): Made static.
5194 * host.c (search_host): Made static.
5195 (search_address): Ditto.
5196 (free_hlist): Ditto.
5198 * ftp.c (getftp): Made static.
5199 (ftp_loop_internal): Ditto.
5200 (ftp_get_listing): Ditto.
5201 (ftp_retrieve_list): Ditto.
5202 (ftp_retrieve_dirs): Ditto.
5203 (ftp_retrieve_glob): Ditto.
5204 (freefileinfo): Ditto.
5205 (delelement): Ditto.
5207 * ftp-ls.c (symperms): Made static.
5208 (ftp_parse_unix_ls): Ditto.
5210 * connect.c (select_fd): Made static.
5212 * utils.c (xmalloc): Renamed from nmalloc.
5213 (xrealloc): Renamed from nrealloc.
5214 (xstrdup): Renamed from nstrdup.
5216 * getopt.c (exchange): Use alloca.
5218 * mswindows.c (mycuserid): Use strncpy.
5220 * New files mswindows.c, mswindows.h, sysdep.h. winjunk.c,
5221 systhings.h, windecl.h and winjunk.h removed.
5223 * mswindows.c (sleep): New function.
5225 * utils.c: Include <windows.h> under Windows.
5227 1997-06-12 Darko Budor <dbudor@zesoi.fer.hr>
5229 * url.h (URL_UNSAFE): Change default under Windows.
5231 * retr.c (retrieve_from_file): Respect opt.delete_after.
5233 * main.c (main): Call ws_help on Windows.
5235 * winjunk.c (windows_main_junk): New function.
5237 * main.c (main): Junk-process argv[0].
5239 * http.c (mktime_from_utc): Return -1 if mktime failed.
5241 * http.c (http_loop): Ditto.
5243 * ftp.c (ftp_loop_internal): Change title on Windows when using a
5246 * winjunk.c (getdomainname): Lots of functions.
5248 1997-06-12 Hrvoje Niksic <hniksic@srce.hr>
5250 * cmpt.c (strptime_internal): Handle years more correctly for
5253 1997-06-09 Mike Thomas <mthomas@reality.ctron.com>
5255 * http.c (gethttp): Allocate enough space for
5256 `Proxy-Authorization' header.
5258 1997-05-10 Hrvoje Niksic <hniksic@srce.hr>
5260 * version.c: Wget/1.4.5 is released.
5262 1997-05-10 Hrvoje Niksic <hniksic@srce.hr>
5264 * retr.c (get_contents): Check return value of fwrite more
5267 1997-03-30 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
5269 * cmpt.c (strptime_internal) [case 'Y']: Always subtract 1900 from
5270 year, regardless of century.
5272 1997-03-30 Hrvoje Niksic <hniksic@srce.hr>
5274 * utils.c (isfile): Use `lstat' instead of `stat'.
5276 1997-03-29 Hrvoje Niksic <hniksic@srce.hr>
5278 * utils.c (numdigit): Use explicit test.
5280 1997-03-21 Hrvoje Niksic <hniksic@srce.hr>
5282 * http.c (http_loop): Always use `url_filename' to get u->local.
5284 1997-03-20 Hrvoje Niksic <hniksic@srce.hr>
5286 * url.c: Recognize https.
5288 1997-03-13 Hrvoje Niksic <hniksic@srce.hr>
5290 * recur.c (recursive_retrieve): Lowercase just the host name.
5292 1997-03-09 Hrvoje Niksic <hniksic@srce.hr>
5294 * url.c (get_urls_file): Use the correct test.
5295 (get_urls_html): Ditto.
5297 1997-03-07 Hrvoje Niksic <hniksic@srce.hr>
5299 * connect.c: Reverted addrlen to int.
5301 * init.c (parse_line): Check for -1 instead of NONE.
5303 * version.c: Changed version to 1.4.5.
5305 1997-02-17 Hrvoje Niksic <hniksic@srce.hr>
5307 * init.c: New option netrc.
5308 (initialize): Don't parse .netrc.
5310 * cmpt.c (recursive): Return rp.
5311 (strptime_internal): Match the long strings first, the abbreviated
5314 1997-02-16 Hrvoje Niksic <hniksic@srce.hr>
5316 * http.c (check_end): New function.
5317 (http_atotm): Use it.
5319 1997-02-13 gilles Cedoc <gilles@cedocar.fr>
5321 * http.c (gethttp): Use them.
5323 * init.c: New options proxy_user and proxy_passwd.
5325 1997-02-14 Hrvoje Niksic <hniksic@srce.hr>
5327 * ftp.c (ftp_retrieve_list): Create links even if not relative.
5329 1997-02-10 Hrvoje Niksic <hniksic@srce.hr>
5331 * recur.c (recursive_retrieve): Lowercase the host name, if the
5332 URL is not "optimized".
5334 * host.c (realhost): Return l->hostname, even if it matches with
5337 1997-02-10 Marin Purgar <pmc@asgard.hr>
5339 * connect.c: Make addrlen size_t instead of int.
5342 1997-02-09 Gregor Hoffleit <flight@mathi.uni-heidelberg.DE>
5344 * systhings.h: Define S_ISLNK on NeXT too.
5346 1997-02-09 Hrvoje Niksic <hniksic@srce.hr>
5348 * version.c: Released 1.4.3.
5350 * url.c: Futher update to list of protostrings.
5351 (skip_proto): Skip `//' correctly for FTP and HTTP.
5353 * url.c (get_urls_html): Handle bogus `http:' things a little
5356 * main.c (main): Removed `follow-ftp' from `f'.
5357 (main): Dumped the `prefix-files' and `file-prefix' options and
5358 features; old and bogus.
5359 (main): Exit on failed setval() in `-e'.
5361 * http.c (fetch_next_header): Use it to detect header continuation
5364 * retr.c (buf_peek): New function.
5366 1997-02-08 Hrvoje Niksic <hniksic@srce.hr>
5368 * wget.h: Include time.h and stuff.
5370 1997-02-08 Roger Beeman <beeman@cisco.com>
5372 * ftp.c: Include <time.h>
5374 1997-02-07 Hrvoje Niksic <hniksic@srce.hr>
5376 * url.c (findurl): Would read over buffer limits.
5378 1997-02-06 Hrvoje Niksic <hniksic@srce.hr>
5380 * ftp-ls.c (ftp_parse_unix_ls): Allow spaces in file names.
5382 1997-02-05 Hrvoje Niksic <hniksic@srce.hr>
5384 * http.c (http_atotm): Initialize tm.is_dst.
5386 1997-02-02 Hrvoje Niksic <hniksic@srce.hr>
5388 * http.c (gethttp): Don't print the number of retrieved headers.
5390 * main.c (main): New option `--no-clobber', alias for `-nc'.
5392 * url.c: Recognize `https://'.
5394 1997-02-01 Hrvoje Niksic <hniksic@srce.hr>
5396 * host.c (herrmsg): Don't use h_errno.
5398 1997-01-30 Hrvoje Niksic <hniksic@srce.hr>
5400 * host.c (accept_domain): Use it.
5402 * main.c (main): New option `--exclude-domains'.
5404 * retr.c (retrieve_url): Use it.
5405 (retrieve_url): Bail out when an URL is redirecting to itself.
5407 * url.c (url_equal): New function.
5409 1997-01-29 Hrvoje Niksic <hniksic@srce.hr>
5411 * connect.c: Include arpa/inet.h instead of arpa/nameser.h.
5413 * http.c (mk_utc_time): New function.
5414 (http_atotm): Use it; handle time zones correctly.
5416 1997-01-28 Hrvoje Niksic <hniksic@srce.hr>
5420 * ftp-basic.c: Use it instead of WRITE.
5422 * connect.c (iwrite): New function.
5424 1997-01-27 Hrvoje Niksic <hniksic@srce.hr>
5426 * cmpt.c (mktime): New function.
5428 * netrc.c: Include <sys/types.h>.
5430 * main.c (main): Wouldn't recognize --spider.
5432 * retr.c (rate): Use `B', `KB' and `MB'.
5433 (reset_timer,elapsed_time): Moved from utils.c.
5435 * ftp.c (ftp_retrieve_list): Ditto.
5437 * http.c (http_loop): Don't touch the file if opt.dfp.
5439 1997-01-24 Hrvoje Niksic <hniksic@srce.hr>
5443 * ftp.c (ftp_retrieve_glob): New argument semantics.
5444 (ftp_retrieve_dirs): Use it.
5447 * html.c (htmlfindurl): Recognize `'' as the quote char.
5449 1997-01-23 Hrvoje Niksic <hniksic@srce.hr>
5451 * ftp.c (ftp_loop_internal): Use it.
5453 * utils.c (remove_link): New function.
5455 1997-01-22 Hrvoje Niksic <hniksic@srce.hr>
5457 * retr.c (retrieve_url): Require STRICT redirection URL.
5459 * url.c (parseurl): New argument STRICT.
5461 * http.c (hparsestatline): Be a little-bit less strict about
5464 1997-01-21 Hrvoje Niksic <hniksic@srce.hr>
5466 * http.c (gethttp): Use it.
5468 * main.c (main): Don't use '<digit>' as options.
5470 * init.c: New option ignore_length.
5472 * http.c (gethttp): Ditto.
5473 (http_loop): Check for redirection without Location:.
5474 (gethttp): Don't print Length unless RETROKF.
5476 * ftp.c (getftp): Use it.
5478 * url.c (mkalldirs): New function.
5480 * utils.c (mymkdir): Don't check for existing non-directory.
5482 * url.c (mkstruct): Don't create the directory.
5484 1997-01-20 Hrvoje Niksic <hniksic@srce.hr>
5486 * init.c (setval): Removed NO_RECURSION checks.
5488 1997-01-19 Hrvoje Niksic <hniksic@srce.hr>
5490 * version.c: "Released" 1.4.3-pre2.
5492 * recur.c (recursive_retrieve): Bypass host checking only if URL
5493 is ftp AND parent URL is not ftp.
5495 * ftp-basic.c (ftp_request): Print out Turtle Power.
5497 * ftp.c (ftp_loop): Call ftp_retrieve_glob with 0 if there's no
5499 (ftp_retrieve_glob): Call ftp_loop_internal even on empty list, if
5502 * http.c (gethttp): Be a little bit smarter about status codes.
5504 * recur.c (recursive_retrieve): Always reset opt.recursive when
5507 1997-01-18 Hrvoje Niksic <hniksic@srce.hr>
5509 * retr.c (retrieve_url): New variable location_changed; use it for
5510 tests instead of mynewloc.
5511 (retrieve_url): Allow heuristic adding of html.
5513 * url.c (url_filename): Don't use the `%' in Windows file names.
5515 * http.c (http_loop): Always time-stamp the local file.
5517 * http.c (http_loop): Ditto.
5519 * ftp.c (ftp_retrieve_list): Use it.
5521 * utils.c (my_touch): New function.
5523 * ftp.c (ftp_retrieve_list): Use #ifdef HAVE_STRUCT_UTIMBUF
5524 instead of #ifndef NeXT.
5526 * utils.c (strptime): New version, by Ulrich Drepper.
5528 1997-01-17 Hrvoje Niksic <hniksic@srce.hr>
5530 * http.c (haccepts_none): Renamed from `haccepts_bytes'.
5531 (gethttp): If haccepts_none(), disable ACCEPTRANGES.
5532 (http_loop): Would remove ACCEPTRANGES.
5534 * ftp.c (getftp): Call ftp_list with NULL.
5536 1997-01-15 Hrvoje Niksic <hniksic@srce.hr>
5538 * html.c (ftp_index): Don't print minutes and seconds if we don't
5539 know them; beautify the output.
5541 * ftp.c (getftp): Don't close the socket on FTPNSFOD.
5543 1997-01-14 Hrvoje Niksic <hniksic@srce.hr>
5545 * utils.c (strptime): New function.
5546 (strptime): Don't use get_alt_number.
5547 (strptime): Don't use locale.
5548 (match_string): Made it a function.
5550 1997-01-12 Hrvoje Niksic <hniksic@srce.hr>
5552 * http.c (http_atotm): New function.
5553 (http_loop): Use it.
5555 * atotm.c: Removed from the distribution.
5557 * http.c (base64_encode_line): Rewrite.
5559 1997-01-09 Hrvoje Niksic <hniksic@srce.hr>
5561 * ftp.c (getftp): Use ftp_expected_bytes; print size.
5563 * ftp-basic.c (ftp_response): Use ftp_last_respline.
5564 (ftp_expected_bytes): New function.
5566 * ftp.c (getftp): Print the unauthoritative file length.
5568 * ftp-ls.c: Renamed from ftp-unix.c.
5569 (ftp_parse_ls): Moved from ftp.c.
5570 (ftp_parse_unix_ls): Recognize seconds in time spec.
5571 (ftp_parse_unix_ls): Recognize year-less dates of the previous
5574 1997-01-08 Hrvoje Niksic <hniksic@srce.hr>
5576 * ftp-basic.c: Don't declare errno if #defined.
5578 * host.c (ftp_getaddress): Check for sysinfo legally.
5580 1997-01-08 Darko Budor <dbudor@diana.zems.fer.hr>
5582 * connect.c (iread): Use READ.
5584 1996-12-23 Hrvoje Niksic <hniksic@srce.hr>
5586 * url.c: Recognize finger, rlogin, tn3270, mid and cid as valid
5589 1996-12-22 Hrvoje Niksic <hniksic@srce.hr>
5591 * host.c (ftp_getaddress): Allow `.' in hostname.
5593 1996-12-26 Darko Budor <dbudor@zems.fer.hr>
5595 * wget.h: READ and WRITE macros for use instead of read and write
5596 on sockets, grep READ *.c, grep WRITE *.c
5598 * wsstartup.c: new file - startup for winsock
5600 * wsstartup.h: new file
5602 * win32decl.h: new file - fixup for <errno.h> and winsock trouble
5604 * configure.bat: Configure utility for MSVC
5606 * src/Makefile.ms,config.h.ms: new files for use with MSVC 4.x
5608 1996-12-22 Hrvoje Niksic <hniksic@srce.hr>
5610 * version.c: Released 1.4.3-pre.
5612 * utils.c (prnum): Accept long.
5613 (legible): Use prnum().
5615 * connect.c (make_connection): Accept port as short.
5618 * http.c (gethttp): Use search_netrc.
5620 1996-12-21 Hrvoje Niksic <hniksic@srce.hr>
5622 * ftp.c (getftp): Use search_netrc.
5624 * netrc.c (free_netrc): New function.
5626 * init.c (home_dir): New function.
5628 * url.c (convert_links): Allow REL2ABS changes.
5630 1996-12-21 Gordon Matzigkeit <gord@gnu.ai.mit.edu>
5632 * netrc.c: New file.
5633 (parse_netrc, maybe_add_to_list): New functions.
5635 1996-12-17 Hrvoje Niksic <hniksic@srce.hr>
5637 * retr.c (retrieve_url): Reset opt.recursion before calling
5638 ftp_loop if it is reached through newloc.
5640 * init.c (run_wgetrc): Print the wgetrc path too, when reporting
5641 error; don't use "Syntax error", since we don't know if it is
5642 really a syntax error.
5644 1996-12-16 Hrvoje Niksic <hniksic@srce.hr>
5646 * utils.c (acceptable): Extract the filename part of the path.
5648 * recur.c (recursive_retrieve): Call acceptable() with the right
5649 argument; would bug out on wildcards.
5651 * init.c (parse_line): Likewise.
5653 * html.c (htmlfindurl): Cast to char * when calling stuff.
5655 1996-12-15 Hrvoje Niksic <hniksic@srce.hr>
5657 * ftp.c (getftp): Use ftp_pasv.
5659 * ftp-basic.c (ftp_request): Accept NULL value.
5660 (ftp_pasv): New function.
5662 * options.h (struct options): Add passive FTP option.
5664 1996-12-15 Hrvoje Niksic <hniksic@srce.hr>
5666 * url.c (parseurl): Debug output.
5668 * utils.c (path_simplify): New one, adapted from bash's
5669 canonicalize_pathname().
5671 1996-12-14 Hrvoje Niksic <hniksic@srce.hr>
5673 * ftp.c (getftp): Don't discard the buffer.
5675 * retr.c (get_contents): New parameter nobuf.
5677 1996-12-13 Shawn McHorse <riffraff@txdirect.net>
5679 * html.c (htmlfindurl): Recognize <meta contents="d; URL=...".
5681 * init.c (setval): Strip the trailing slashes on CVECDIR.
5683 1996-12-13 Hrvoje Niksic <hniksic@srce.hr>
5685 * init.c: Make excludes and includes under CVECDIR instead of
5688 1996-12-13 Shawn McHorse <riffraff@txdirect.net>
5690 * url.c (get_urls_html): Skip "http:".
5692 1996-12-13 Hrvoje Niksic <hniksic@srce.hr>
5694 * utils.c (strcasecmp): From glibc.
5695 (strncasecmp): Also.
5698 * url.c: Added javascript: to the list of URLs prefixes.
5700 1996-12-12 Shawn McHorse <riffraff@txdirect.net>
5702 * recur.c (retrieve_robots): Print the warning message only if
5705 1996-12-12 Gregor Hoffleit <flight@mathi.uni-heidelberg.DE>
5707 * ftp.c (ftp_retrieve_list): Use NeXT old utime interface.
5709 1996-12-12 Hrvoje Niksic <hniksic@srce.hr>
5711 * systhings.h: New file.
5713 * ../configure.in: Check for utime.h
5715 * ftp.c: Check whether we have unistd.h.
5717 1996-11-27 Hrvoje Niksic <hniksic@srce.hr>
5719 * recur.c (recursive_retrieve): Send the canonical URL as referer.
5720 (recursive_retrieve): Call get_urls_html with the canonical URL.
5722 1996-12-13 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
5724 * (configure.in, config.h.in, src/Makefile.in, src/*.[ch]): Add
5725 ansi2knr support for compilers which don't support ANSI style
5726 function prototypes and signatures.
5728 * (aclocal.m4, src/ansi2knr.c, src/ansi2knr.1): New files.
5730 1996-11-26 Hrvoje Niksic <hniksic@srce.hr>
5732 * url.c: Use it; Recognize paths ending with "." and ".." as
5734 (url_filename): Append .n whenever file exists and could be a
5737 * url.h (ISDDOT): New macro.
5739 * init.c (parse_line): Use unsigned char.
5741 * url.c (get_urls_html): Cast to unsigned char * when calling
5744 * html.c (htmlfindurl): Use unsigned char.
5746 * version.c: Changed version to 1.4.3.
5748 1996-11-25 Hrvoje Niksic <hniksic@srce.hr>
5750 * version.c: Released 1.4.2.
5752 * ftp.c (getftp): Simplified assertion.
5753 (ftp_loop_internal): Remove symlink before downloading.
5754 (ftp_retrieve_list): Unlink the symlink name before attempting to
5757 * options.h (struct options): Renamed print_server_response to
5760 * ftp.c (rel_constr): Removed.
5761 (ftp_retrieve_list): Don't use it.
5762 (ftp_retrieve_list): Use opt.retr_symlinks.
5764 1996-11-24 Hrvoje Niksic <hniksic@srce.hr>
5766 * main.c (main): New option retr_symlinks.
5768 * url.c (convert_links): Print verbose message.
5770 1996-11-24 Hrvoje Niksic <hniksic@srce.hr>
5772 * http.c (http_loop): Reset newloc in the beginning of function;
5773 would cause FMR in retrieve_url.
5775 1996-11-23 Hrvoje Niksic <hniksic@srce.hr>
5777 * recur.c (convert_all_links): Find the URL of each HTML document,
5778 and feed it to get_urls_html; would bug out.
5779 (convert_all_links): Check for l2 instead of dl; removed dl.
5781 * url.c (convert_links): Don't refer to freed newname.
5783 * recur.c (recursive_retrieve): Add this_url to urls_downloaded.
5785 * main.c (main): Print the OS_TYPE in the debug output, too.
5787 * recur.c (recursive_retrieve): Check for opt.delete_after.
5789 * main.c (main): New option delete-after.
5791 * init.c (setval): Cleaned up.
5793 1996-11-21 Hrvoje Niksic <hniksic@srce.hr>
5795 * Makefile.in (wget): Make `wget' the default target.
5797 * ftp.c (ftp_loop_internal): Move noclobber checking out of the
5799 (ftp_retrieve_list): Warn about non-matching sizes.
5801 * http.c (http_loop): Made -nc non-dependent on opt.recursive.
5803 * init.c (setnum): Renamed from setnuminf; New argument flags.
5806 * main.c (main): Sorted the options.
5807 (main): New option --wait.
5809 1996-11-21 Shawn McHorse <riffraff@txdirect.net>
5811 * html.c (htmlfindurl): Reset s->in_quote after getting out of
5814 1996-11-20 Hrvoje Niksic <hniksic@srce.hr>
5816 * version.c: Changed version to 1.4.2.
5818 1996-11-20 Hrvoje Niksic <hniksic@srce.hr>
5820 * version.c: Released 1.4.1.
5822 * html.c (html_quote_string): New function.
5823 (ftp_index): Use it.
5824 (htmlfindurl): A more gentle ending debug message.
5826 * ftp.c (ftp_loop): Check for opt.htmlify.
5828 * init.c: New command htmlify.
5830 * ftp.c (getftp): Nicer error messages, with `'-encapsulated
5832 (ftp_loop): Print size of index.html.
5834 * init.c (setval): Implement "styles".
5836 * main.c (main): New option dotstyle.
5838 1996-11-19 Hrvoje Niksic <hniksic@srce.hr>
5840 * ftp.c (getftp): Close the master socket in case of errors, after
5843 * connect.c (bindport): Initialize msock to -1.
5845 * ftp.c (getftp): Initialize dtsock to -1.
5847 * connect.c (closeport): Don't close sock if sock == -1.
5849 1996-11-18 Hrvoje Niksic <hniksic@srce.hr>
5851 * init.c (setnuminf): Nuked default value -- just leave unchanged.
5852 (setval): Don't send default values.
5853 (defaults): Use DEFAULT_TIMEOUT -- aaargh.
5855 * options.h (struct options): Use long for dot_bytes.
5857 * init.c (setquota): Renamed to setbytes.
5858 (setval): Use setbytes on DOTBYTES.
5860 1996-11-17 Hrvoje Niksic <hniksic@srce.hr>
5862 * ftp.c (getftp): Initialize con->dltime.
5864 * recur.c (recursive_retrieve): Use same_host instead of
5865 try_robots; simply load robots_txt whenever the host is changed.
5866 (recursive_retrieve): Free forbidden before calling parse_robots.
5868 1996-11-16 Hrvoje Niksic <hniksic@srce.hr>
5870 * retr.c (show_progress): Use them.
5872 * options.h (struct options): New options dot_bytes, dots_on_line
5875 1996-11-16 Mark Boyns <boyns@sdsu.edu>
5877 * recur.c (recursive_retrieve): Retrieve directories regardless of
5878 acc/rej rules; check for empty u->file.
5880 1996-11-14 Hrvoje Niksic <hniksic@srce.hr>
5882 * init.c (setval): Use it.
5884 * utils.c (merge_vecs): New function.
5886 * init.c (setval): Reset the list-type functions when encountering
5889 1996-11-14 Shawn McHorse <riffraff@txdirect.net>
5891 * recur.c (recursive_retrieve): Use base_url instead of this_url
5894 1996-11-14 Shawn McHorse <riffraff@txdirect.net>
5896 * html.c (htmlfindurl): Reset s->in_quote after exiting the quote.
5898 1996-11-13 Hrvoje Niksic <hniksic@srce.hr>
5900 * utils.c (sepstring): Rewrote; don't use strtok.
5902 * recur.c (recursive_retrieve): Enter assorted this_url to slist
5903 when running the first time.
5904 (retrieve_robots): Warn to ignore errors when robots are loaded.
5906 * utils.c (load_file): Moved from url.c.
5908 * http.c: Made static variables const too in h* functions.
5910 * main.c (main): Renamed --continue-ftp to --continue.
5912 * recur.c (recursive_retrieve): Use it.
5914 * utils.c (frontcmp): New function.
5916 * url.c (accdir): New function.
5918 * html.c (htmlfindurl): Recognize <area href=...>.
5920 * ftp.c (ftp_retrieve_dirs): Implemented opt.includes.
5922 * init.c (setval): Free the existing opt.excludes and
5923 opt.includes, if available.
5925 * main.c (main): New option -I.
5927 1996-11-12 Hrvoje Niksic <hniksic@srce.hr>
5929 * ftp.c (ftp_retrieve_glob): Do not weed out directories.
5931 * version.c: Changed version to 1.4.1.
5933 1996-11-11 Hrvoje Niksic <hniksic@srce.hr>
5935 * version.c: Released 1.4.0.
5937 1996-11-10 Hrvoje Niksic <hniksic@srce.hr>
5939 * main.c (main): Free com and val after parse_line.
5940 (printhelp): Reorder the listing.
5942 * http.c: More robust header parsing.
5944 * http.c: Allow any number of spaces, or no spaces, precede ':'.
5945 (hskip_lws): New function.
5946 (haccepts_bytes): New function.
5949 * init.c (setval): Check header sanity.
5950 (setval): Allow resetting of headers.
5952 1996-11-10 Hrvoje Niksic <hniksic@srce.hr>
5954 * http.c (http_loop): Don't use has_wildcards.
5956 * http.c (gethttp): Free all_headers -- would leak.
5958 * recur.c (recursive_retrieve): Initialize depth to 1 instead of
5959 0 -- this fixes a long-standing bug in -rl.
5961 1996-11-09 Hrvoje Niksic <hniksic@srce.hr>
5963 * ftp.c: Use -1 as "impossible" value for con->fd.
5965 * url.h (URL_SEPARATOR): Don't treat `*' and `+' as separators.
5967 * init.c (parse_line): Use isalpha.
5969 * ftp-unix.c: Use HAVE_UNISTD_H.
5971 * mtch.c (has_wildcards): Don't match \.
5973 * http.c (http_loop): Warn on HTTP wildcard usage.
5975 1996-11-08 Hrvoje Niksic <hniksic@srce.hr>
5977 * url.c (url_filename): Do not create numbered suffixes if
5978 opt.noclobber -- would bug out on -nc.
5980 1996-11-07 Hrvoje Niksic <hniksic@srce.hr>
5982 * recur.c (parse_robots): Don't chuck out the commands without
5983 arguments (`Disallow:<empty>' didn't work).
5984 (parse_robots): Compare versions lowercase.
5985 (parse_robots): Match on base_version, not version_string!
5986 (parse_robots): Handle comments properly.
5987 (parse_robots): Match versions in a sane way.
5989 * init.c: Print nicer error messages.
5991 * version.c: Changed version to 1.4.0.
5993 1996-11-06 Hrvoje Niksic <hniksic@srce.hr>
5995 * version.c: Released 1.4.0-test2.
5997 * init.c (run_wgetrc): Close fp.
5999 * ftp.c (ftp_retrieve_dirs): Allocate the correct length for
6002 1996-11-06 Hrvoje Niksic <hniksic@srce.hr>
6004 * init.c (setquota): Allow inf as quota specification.
6006 1996-11-05 Hrvoje Niksic <hniksic@srce.hr>
6008 * ftp.c (ftp_retrieve_dirs): Return QUOTEXC if quota exceeded.
6009 (ftp_retrieve_glob): Return QUOTEXC on quota exceeded.
6011 * main.c (main): Check for quota by comparison with downloaded
6012 stuff, not from status.
6014 * connect.c (select_fd): Should compile on HPUX without warnings now.
6016 * ftp.c (ftp_get_listing): Check whether ftp_loop_internal
6019 1996-11-04 Hrvoje Niksic <hniksic@srce.hr>
6021 * ftp.c (ftp_retrieve_glob): Print the pattern nicely.
6022 (getftp): Return FTPRETRINT on control connection error.
6024 * html.c (htmlfindurl): Recognize <embed src=...> and
6026 (ftp_index): Handle username and password correctly.
6028 * main.c (main): Made `-np' a synonim for --no-parent.
6030 1996-11-02 Hrvoje Niksic <hniksic@srce.hr>
6032 * ftp.c (ftp_loop): Check for opt.ftp_glob too before calling
6035 * version.c: Changed version to 1.4.0-test2.
6037 1996-11-02 Hrvoje Niksic <hniksic@srce.hr>
6039 * version.c: Released 1.4.0-test1.
6041 * url.c (str_url): Don't use sprintf when creating %2F-prefixed
6043 (convert_links): Removed definition of make_backup.
6045 * http.h: Removed definition of MAX_ERROR_LENGTH.
6047 * host.c (ftp_getaddress): Check for "(none)" domains.
6049 * ftp.c (ftp_retrieve_dirs): Docfix.
6051 * http.c (gethttp): Use ou->referer instead of u->referer.
6053 * retr.c (retrieve_url): Reset u to avoid freeing pointers twice;
6054 this was known to cause coredumps on Linux.
6056 * html.c (ftp_index): Cast the argument to local_time to time_t *.
6058 1996-11-01 Hrvoje Niksic <hniksic@srce.hr>
6060 * connect.c (select_fd): Use exceptfds -- once and for all.
6062 * retr.c (retrieve_from_file): Free filename after
6064 (retrieve_from_file): Send RFIRST_TIME to recursive_retrieve on
6065 first-time retrieval.
6066 (retrieve_from_file): Return uerr_t; new argument, count.
6067 (retrieve_from_file): Break on QUOTEXC.
6069 * init.c (setquota): Fixed a bug that caused rejection of
6070 non-postfixed values..
6072 1996-10-30 Hrvoje Niksic <hniksic@srce.hr>
6074 * version.c: Changed name to wget.
6076 * connect.c (iread): Smarter use of select.
6077 (select_fd): Set errno on timeout. If not timeout, return 1
6080 1996-10-29 Hrvoje Niksic <hniksic@srce.hr>
6082 * ftp.c (ftp_loop_internal): Don't use con->cmd before
6085 1996-10-26 Hrvoje Niksic <hniksic@srce.hr>
6087 * http.c (gethttp): Send correct referer when using proxy.
6088 (gethttp): Use struct urlinfo ou to access the relevant data; send
6089 correct authorization in all cases.
6091 * host.c (same_host): Use skip_uname to skip username and
6094 * url.c (skip_uname): New function.
6097 * host.c (same_host): Do not assume HTTP -- same_host should now
6098 be totally foolproof.
6100 * url.c (skip_proto): New function.
6101 (parse_uname): Use it.
6103 * http.c (gethttp): Create local user and passwd from what is
6106 * url.c (parseurl): Check for HTTP username and password too.
6108 1996-10-25 Hrvoje Niksic <hniksic@srce.hr>
6110 * config.h.in: Removed #define gethostbyname R...
6112 1996-10-22 Hrvoje Niksic <hniksic@srce.hr>
6114 * version.c: Changed version to 1.4.0-test1.
6116 1996-10-21 Hrvoje Niksic <hniksic@srce.hr>
6118 * version.c: "Released" 1.4b29.
6120 * recur.c (recursive_retrieve): Check for no_parent.
6122 * init.c (setval): Option update.
6124 * main.c (main): New option no-parent.
6126 * options.h (struct options): New variable no_parent.
6128 * recur.c (recursive_retrieve): Only files are checked for
6129 opt.accepts and opt.rejects.
6130 (recursive_retrieve): Check directories for opt.excludes.
6131 (recursive_retrieve): Make the dir absolute when checking
6134 * html.c (htmlfindurl): Recognize <applet code=...> and <script
6137 1996-10-18 Hrvoje Niksic <hniksic@srce.hr>
6139 * ftp.c (getftp): Do not line-break assert entries at all.
6140 (ftp_retrieve_dirs): docfix.
6142 * connect.c (select_fd): Use fd + 1 as nfds.
6144 * version.c: Changed version to 1.4b29.
6146 1996-10-18 Hrvoje Niksic <hniksic@srce.hr>
6148 * version.c: "Released" 1.4b28.
6150 * ftp.c (ftp_loop_internal): Check whether f->size == len and
6151 don't continue the loop if it is.
6152 (ftp_get_listing): Remove list_filename on unsuccesful loop.
6154 1996-10-17 Hrvoje Niksic <hniksic@srce.hr>
6156 * ftp.c (ftp_loop_internal): Use strcpy to initialize tmp.
6157 (getftp): Do not use multiline assert.
6159 * http.c (hparsestatline): Use mjr and mnr instead of major and
6160 minor, which don't compile on Ultrix.
6161 (http_loop): Use strcpy() to initialize tmp.
6163 * all: Geturl -> Fetch
6165 1996-10-17 Hrvoje Niksic <hniksic@srce.hr>
6167 * recur.c (parse_robots): Fixed an off-by-one bug when looking for
6170 * html.c (htmlfindurl): Fixed several possible off-by-one bugs by
6171 moving `bufsize &&' to the beginning of each check in for-loops.
6173 * recur.c (parse_robots): Close fp on exit.
6175 * url.c (mymkdir): Check for each directory before creating.
6177 1996-10-16 Hrvoje Niksic <hniksic@srce.hr>
6179 * version.c: Changed version to 1.4b28.
6181 1996-10-16 Hrvoje Niksic <hniksic@srce.hr>
6183 * version.c: "Released" 1.4b27.
6185 * init.c (parse_line): Use isspace.
6186 (parse_line): Free *com on all errors.
6188 * ftp.c (ftp_loop): Change FTPOK to RETROK before exiting.
6189 (delelement): Use next instead of f->next and prev instead of
6191 (delelement): Free the members of the deleted element.
6193 * http.c (http_loop): Do not return RETROK on code != 20x.
6195 * init.c (cleanup): Free opt.user_header.
6196 (cleanup): Free opt.domains.
6198 * url.c (freelists): Moved to cleanup().
6200 * http.c (hparsestatline): Docfix.
6202 * main.c (main): Return with error status on unsuccesful
6205 * init.c (setval): Do not remove listing when mirroring.
6207 * url.c (url_filename): Use opt.fileprefix.
6209 * ftp.c (ftp_get_listing): Use url_filename to get filename for
6212 * main.c (main): New option: -rn.
6214 1996-10-15 Hrvoje Niksic <hniksic@srce.hr>
6216 * Makefile.in (RM): Added RM = rm -f.
6218 * host.c (clean_hosts): New function.
6219 (free_hlist): Just free the list, no reset.
6221 * version.c: Changed version to 1.4b27.
6223 1996-10-13 Hrvoje Niksic <hniksic@srce.hr>
6225 * version.c: "Released" 1.4b26.
6227 * retr.c (retrieve_from_file): If call get_urls_html with
6228 opt.spider to make it silent in spider mode.
6230 * url.c (str_url): Use CLEANDUP instead of URL_CLEANSE.
6232 * url.h (CLEANDUP): New macro.
6234 * http.c (gethttp): Fixed a bug that freed location only when it
6237 * retr.c (retrieve_url): Free url if it will not be stored,
6238 i.e. newloc is NULL.
6240 * html.c (htmlfindurl): Handle exiting from quotes correctly; the
6241 old version would bug out on <a href="x#a"href="y">.
6243 * html.h (state_t): New member in_quote.
6245 * html.c (htmlfindurl): Free s->attr at the beginning of
6248 * recur.c (recursive_retrieve): Recognize RCLEANUP.
6249 (tried_robots): Make hosts a global variable.
6250 (recursive_retrieve): Free constr after URL host optimization.
6251 (tried_robots): Free urlinfo before exiting.
6253 * utils.c (free_slist): New function.
6255 * recur.c (recursive_retrieve): Use flags to add cleanup
6258 * main.c (main): Free filename after recursive_retrieve.
6260 * http.c (gethttp): Store successful responses too.
6262 1996-10-12 Hrvoje Niksic <hniksic@srce.hr>
6264 * all: Constified the whole source. This required some minor
6265 changes in many functions in url.c, possibly introducing bugs -- I
6268 * ftp-basic.c: Removed last_respline.
6270 * http.c (gethttp): Free type.
6272 * host.c (same_host): Free real1 and real2.
6274 * main.c (main): New option --spider.
6276 * retr.c (get_contents): Don't reset errno.
6278 * main.c (main): Sorted the options.
6280 * connect.c (iread): Set errno to ETIMEDOUT only if it was left
6281 uninitialized by select().
6283 * http.c (http_loop): Print the time when the connection is
6285 (gethttp): Debug-print the HTTP request.
6287 1996-10-11 Hrvoje Niksic <hniksic@srce.hr>
6289 * connect.c (iread): Do not try reading after timeout.
6291 * main.c (main): Would bug out on -T.
6293 * connect.c (select_fd): Do not use exceptfds.
6294 (iread): Set ETIMEDOUT on select_fd <= 0.
6296 * version.c: Changed version to 1.4b26.
6298 1996-10-10 Hrvoje Niksic <hniksic@srce.hr>
6300 * version.c: "Released" 1.4b25.
6302 * ftp-unix.c (ftp_parse_unix_ls): Ignore lines without file name
6305 * http.c (gethttp): Add errcode to struct hstat.
6306 (http_loop): Use it.
6308 * url.c (no_proxy_match): Simplify using char** for no_proxy.
6310 * options.h (struct options): Make opt.no_proxy a vector.
6312 * utils.c (sepstring): Use !*s instead of !strlen(s).
6314 * init.c (setval): Set opt.maxreclevel to 0 on --mirror.
6315 (getperms): Use ISODIGIT instead of isdigit.
6317 * ftp.c (getftp): Print time.
6319 * main.c (main): Use legible output of downloaded quantity.
6321 * ftp.c (getftp): Use elapsed_time().
6322 (ftp_loop_internal): Use rate().
6324 * http.c (http_loop): Add download ratio output; Use rate().
6326 * utils.c (rate): New function.
6328 1996-10-09 Hrvoje Niksic <hniksic@srce.hr>
6330 * http.c (http_loop): Use timer.
6332 * ftp.c: Split to ftp-basic.c and ftp.c
6334 * utils.c (reset_timer): New function.
6335 (elapsed_time): New function.
6337 * retr.c (show_progress): Make bytes_in_line and offs long; should
6338 work on 16-bit machines.
6340 1996-10-08 Hrvoje Niksic <hniksic@srce.hr>
6342 * url.c (in_acclist): New argument backward.
6344 * ftp.c (ftp_retrieve_glob): Use acceptable() to determine whether
6345 a file should be retrieved according to suffix.
6346 (ftp_get_listing): Check the return value of unlink; Do not call
6347 ftp_retrieve_dirs if depth reached maxreclevel.
6348 (ftp_retrieve_dirs): Check whether the directory is in
6351 * main.c (main): Print the version number at the beginning of
6353 (main): Use strrchr when creating exec_name.
6355 * ftp.c (ftp_retrieve_glob): Do not close control connection.
6357 * version.c: Changed version to 1.4b25.
6359 1996-10-07 Hrvoje Niksic <hniksic@srce.hr>
6361 * version.c: "Released" 1.4b24.
6363 * Makefile.in: Rewrite.
6365 * ftp.c (ftp_loop_internal): Likewise.
6367 * retr.c (time_str): Check for failed time().
6369 * html.c (htmlfindurl): Recognize <fig src> and <overlay src> from
6372 * retr.c (time_str): Return time_t *.
6374 * connect.c (bindport): Close msock on unsuccesful bind.
6375 (bindport): The same for getsockname and listen.
6377 * retr.c (retrieve_url): Allow any number of retries on
6380 * http.c (gethttp): Do not treat errno == 0 as timeout.
6381 (http_loop): Likewise.
6382 (http_loop): Cosmetic changes.
6384 * connect.c (iread): Set errno to ETIMEDOUT in case of timeout.
6386 * retr.c (get_contents): Reset errno.
6388 * ftp.c (getftp): Minor fixes.
6390 1996-10-06 Hrvoje Niksic <hniksic@srce.hr>
6392 * http.c: Do not use backups.
6394 * geturl.1 (WARNING): Warn that man-page could be obsolete.
6396 * getopt.c (getopt_long): Moved to getopt.c
6398 * geturl.texi: Enhanced.
6400 * main.c (main): Use it.
6402 * recur.c (convert_all_links): New function.
6404 * utils.c (add_slist): New argument flags.
6406 * recur.c (recursive_retrieve): Update a list of downloaded URLs.
6407 (parse_robots): Do not chuck out empty value fields.
6408 (parse_robots): Make yourself welcome on empty Disallow.
6410 * version.c: Changed version to 1.4b24.
6412 1996-10-06 Hrvoje Niksic <hniksic@srce.hr>
6414 * version.c: "Released" 1.4b23.
6416 * ftp.c (ftp_loop_internal): Get the time after getftp.
6418 * Makefile.in (install.info): New target.
6421 * http.c (http_loop): Fix output when doing -O.
6423 1996-10-05 Hrvoje Niksic <hniksic@srce.hr>
6425 * geturl.texi: New file.
6427 * main.c (main): Do not print the warnings and download summary if
6430 * version.c: Changed version to 1.4b23.
6432 1996-10-05 Hrvoje Niksic <hniksic@srce.hr>
6434 * "Released" 1.4b22.
6436 * atotm.c (atotm): Use True and False instead of TRUE and FALSE,
6437 to avoid redefinition warnings.
6439 * host.c (store_hostaddress): Use memcpy() to copy the address
6440 returned by inet_addr.
6442 * version.c: Changed version to 1.4b22.
6444 1996-10-04 Hrvoje Niksic <hniksic@srce.hr>
6446 * version.c: "Released" 1.4b21.
6448 * ftp-unix.c (ftp_parse_ls): Renamed to ftp_parse_unix_ls.
6450 * ftp.c (ftp_port): Use conaddr.
6451 (getftp): Print the file length.
6452 (ftp_retrieve_list): Check the stamps of plain files only.
6454 * connect.c (closeport): Do not call shutdown().
6455 (conaddr): New function.
6457 * html.c (ftp_index): Made it dfp-aware.
6459 * init.c (cleanup): New name of freemem. Close opt.dfp.
6461 * ftp.c (getftp): Use opt.dfp if it is set.
6463 * ftp-unix.c (ftp_parse_ls): Recognize time in h:mm format.
6465 * ftp.c (ftp_retrieve_dirs): Fixed a bug that caused incorrect
6466 CWDs to be sent with recursive FTP retrievals.
6468 1996-10-03 Hrvoje Niksic <hniksic@srce.hr>
6470 * recur.c (parse_robots): Made it more compliant with "official"
6473 * http.c: New function.
6475 * ftp-unix.c (ftp_parse_ls): Added better debug output.
6477 * ftp.c (getftp): Print out the LIST in case of
6478 opt.print_server_response.
6480 * version.c: Changed version to 1.4b21.
6482 1996-10-01 Hrvoje Niksic <hniksic@srce.hr>
6484 * version.c: "Released" 1.4b20.
6488 * http.c (gethttp): Preset lengths of various headers instead of
6489 calculating them dynamically.
6490 (gethttp): Check for 206 partial contents.
6492 1996-09-30 Hrvoje Niksic <hniksic@srce.hr>
6494 * configure.in: Set SYSTEM_GETURLRC to $libdir/geturlrc
6496 * http.c (gethttp): Send the port number in the Host: header.
6498 1996-09-29 Hrvoje Niksic <hniksic@srce.hr>
6500 * http.c (gethttp): Send host: header.
6501 (gethttp): Add the possibility of user-defined headers.
6502 (gethttp): Move decision about pragma: no-cache to http_loop,
6504 (gethttp): Pass a struct instead of enormous argument list.
6505 (http_loop): Use a new, fancier display format.
6506 (ftp_loop): Likewise.
6508 * main.c: (hangup): Turn off buffering of the new log file.
6510 * install-sh: Likewise.
6512 * config.sub: Replace with the one in autoconf-2.10
6516 * init.c: New options httpuser and httppasswd.
6518 * http.c: (base64_encode_line): New function.
6519 (gethttp): Send authentication.
6521 * connect.c (make_connection): Use store_hostaddress.
6523 1996-09-28 Hrvoje Niksic <hniksic@srce.hr>
6525 * host.c (store_hostaddress): New function.
6529 * http.c (hgetrange): New function.
6530 (gethttp): Use ranges.
6532 * utils.c (numdigit): Accept long instead of int.
6534 * http.c (http_loop): Add restart capabilities.
6536 * ftp.c (ftp_retrieve_glob): Fixed a bug that could cause matchres
6537 being used uninitialized.
6538 (ftp_retrieve_list): Similar fix.
6540 * host.c (add_hlist): Fixed a bug that could cause cmp being used
6543 * url.c (construct_relative): New function.
6545 * recur.c (recursive_retrieve): Use it.
6547 * retr.c (convert_links): New function.
6549 1996-09-27 Hrvoje Niksic <hniksic@srce.hr>
6551 * url.c (free_urlpos): New function.
6553 * recur.c (recursive_retrieve): Adapt.
6555 * url.c (get_urls_html): Return a linked list instead of a vector.
6557 * url.c (get_urls_file): Return a linked list instead of a vector.
6561 * http.c (gethttp): Implement it.
6563 * init.c (setval): New option: SAVEHEADERS
6565 * ftp.c (ftp_loop_internal): Do not set restval if listing is to
6566 be retrieved. Lack of this test caused bugs when the connection
6567 was lost during listing.
6569 * retr.c (retrieve_url): Fixed a bug that caused
6570 coredumps. *newloc is now reset by default.
6571 (retrieve_url): Lift the twenty-tries limit on proxies.
6573 * version.c: Changed version to 1.4b20.
6575 1996-09-20 Hrvoje Niksic <hniksic@srce.hr>
6577 * version.c: "Released" 1.4b19.
6579 1996-09-19 Hrvoje Niksic <hniksic@srce.hr>
6581 * ftp.c (ftp_loop_internal): Renamed from ftp_1fl_loop.
6582 (getftp): Changed prototype to accept ccon *.
6584 1996-09-17 Hrvoje Niksic <hniksic@srce.hr>
6586 * ftp.c (ftp_retrieve_list): Fixed a bug that caused setting
6587 incorrect values to files pointed to by symbolic links.
6588 (ftp_1fl_loop): Do not count listings among the downloaded URL-s.
6590 1996-09-16 Hrvoje Niksic <hniksic@srce.hr>
6592 * url.c (mkstruct): Do not prepend "./" in front of a pathname.
6594 * main.c (main): New option: --user-agent.
6600 * init.c (setval): Ditto.
6602 * main.c (main): Rename "server-headers" to "server-response".
6604 * ftp-unix.c (ftp_parse_ls): Check for asterisks at the end of
6605 executables in 'ls -F' listings.
6607 1996-09-15 Hrvoje Niksic <hniksic@srce.hr>
6609 * url.c (parseurl): Remove realloc() and sprintf().
6610 (str_url): Get rid of sprintf().
6612 * recur.c (recursive_retrieve): Enable FTP recursion through proxy
6615 * url.h (URL_CLEANSE): Made it else-resistant.
6616 (USE_PROXY): New macro.
6618 1996-09-14 Hrvoje Niksic <hniksic@srce.hr>
6622 * version.c: Changed version to 1.4b19.
6624 1996-09-14 Hrvoje Niksic <hniksic@srce.hr>
6626 * version.c: "Released" 1.4b18.
6628 * url.c: Made it reallocate space exponentially.
6630 1996-09-14 Drazen Kacar <dave@fly.cc.fer.hr>
6632 * html.c (htmlfindurl): Added <frame src> and <iframe src> among
6633 the list of stuff to fetch.
6635 1996-09-13 Hrvoje Niksic <hniksic@srce.hr>
6637 * url.c (get_urls_html): Fixed a bug that caused SIGSEGV's with
6640 * html.c (htmlfindurl): Rewrite.
6642 * http.c (gethttp): Use opt.proxy_cache.
6644 * main.c (main): Added --cache option.
6646 * ftp.c (ftp_response): Print server response if opt.print_server
6648 (getftp): Print newlines after each request if the server response
6650 (ftp_response): Copy the last response line to last_respline.
6652 * http.c (gethttp): Add Pragma: nocache for retried
6655 * ftp.c (getftp): Use it.
6657 * retr.c (buf_discard): New function.
6659 * ftp.c (ftp_response): Use buf_readchar().
6660 (getftp): Flush the control connection buffer before calling
6663 * retr.c (buf_readchar): New function.
6664 (buf_flush): New function.
6665 (get_contents): Use buf_readchar() instead of read(x, x, 1).
6666 (get_contents): Use buf_flush.
6668 1996-09-12 Hrvoje Niksic <hniksic@srce.hr>
6670 * ftp.c: Incorporate changes to ftp_response.
6672 * ftp.c (ftp_response): Allocate the server response dynamically,
6673 as in read_whole_line and fetch_next_header.
6675 * utils.c (read_whole_line): Fixed a bug that prevented reading
6676 the last line if it is not \n-terminated. Also fixed a possible
6679 * http.c (fetch_next_header): Return malloc-ed string as large as
6681 (gethttp): Use new fetch_next_header.
6683 1996-09-12 Hrvoje Niksic <hniksic@srce.hr>
6685 * http.c (hgetlen): Compute the header length the first time only.
6687 (hgetlocation): Ditto.
6688 (hgetmodified): Ditto.
6690 1996-09-11 Hrvoje Niksic <hniksic@srce.hr>
6692 * sample.geturlrc: Update.
6694 1996-09-10 Hrvoje Niksic <hniksic@srce.hr>
6696 * http.c (http_loop): Ditto.
6698 * ftp.c (getftp): Open the output file as binary.
6700 * version.c: Changed version to 1.4b18.
6702 1996-09-10 Hrvoje Niksic <hniksic@srce.hr>
6704 * version.c: "Released" 1.4b17.
6706 * ftp-unix.c (ftp_parse_ls): If unable to open file, return NULL
6707 instead of failed assertion.
6709 1996-09-09 Hrvoje Niksic <hniksic@srce.hr>
6711 * ftp.c (ftp_get_listing): Add a numbered suffix to LIST_FILENAME
6712 if a file of that name already exists.
6714 1996-09-05 Hrvoje Niksic <hniksic@srce.hr>
6716 * ftp.c (ftp_1fl_loop): Handler FTPPORTERR and FOPENERR correctly.
6718 * config.h.in: Define gethostbyname as Rgethostbyname when using
6721 * configure.in: Check for -lresolv if using Socks.
6723 * version.c: Changed version to 1.4b17.
6725 1996-07-15 Hrvoje Niksic <hniksic@srce.hr>
6727 * version.c: "Released" 1.4b16.
6729 * http.c (gethttp): More intelligent check for first line of HTTP
6731 (gethttp): Would bug out on time-stamping.
6733 * version.c: Changed version to 1.4b16.
6735 1996-07-11 Hrvoje Niksic <hniksic@srce.hr>
6737 * version.c: Released 1.4b15.
6739 * http.c (http_loop): Print \n after the loop entry, not before.
6741 * url.c (url_filename): Use ISDOT.
6743 * url.h (ISDOT): New macro.
6745 * recur.c (recursive_retrieve): Change only opt.recursive for
6748 1996-07-11 Antonio Rosella <antonio.rosella@agip.it>
6750 * socks/geturl.cgi: Fixed version No.
6752 * socks/download-netscape.html: Ditto.
6754 * socks/download.html: Changed socks.html to download.html.
6756 1996-07-11 Hrvoje Niksic <hniksic@srce.hr>
6758 * url.c (url_filename): Check for opt.dirstruct instead for
6759 opt.recursive && opt.dirstruct.
6761 * init.c (defaults): Ditto.
6762 (defaults): Reset dirstruct by default.
6763 (setval): Set opt.dirstruct whenever setting recursive.
6765 * init.h: Removed FORCEDIRHIER.
6767 * INSTALL: Added -L to socks-description.
6769 * version.c: Changed version to 1.4b15.
6771 1996-07-10 Hrvoje Niksic <hniksic@srce.hr>
6773 * version.c: "Released" 1.4b14.
6775 * geturl.1: Update AUTHOR to include Rosella as contributor.
6779 * socks/geturl.cgi: Simplified command creation, nuked <blink>.
6781 * socks/geturl.cgi: Wrap nutscape extensions within if $netscape.
6782 (cal_time): Fix == to eq.
6784 * socks/geturl.cgi: GPL-ized with permission of A. Rosella.
6786 * geturl.1 (hostname): Moved URL CONVENTIONS to the beginning.
6788 * Makefile.in: Use @VERSION@.
6790 * configure.in: Check version from version.c.
6792 * socks/geturl.cgi: Changed /pub/bin/perl to /usr/bin/perl.
6794 * socks/download.html: Created from download-netscape.html, made
6797 * recur.c (recursive_retrieve): Set opt.force_dir_hier when
6798 following FTP links from recursions.
6800 1996-07-09 Hrvoje Niksic <hniksic@srce.hr>
6802 * url.c (mymkdir): Fixed a bug that prevented mymkdir() to create
6803 absolute directories correctly.
6805 * version.c: Changed version to 1.4b14.
6807 1996-07-09 Hrvoje Niksic <hniksic@srce.hr>
6809 * version.c: "Released" 1.4b13.
6811 * url.c (make_backup): New function.
6813 * http.c (http_loop): Make a backup copy of the local file (using
6814 rename(2)) before opening it.
6816 * main.c (main): Added --backups.
6818 * host.c (ftp_getaddress): Bail out on failed mycuserid().
6819 (ftp_getaddress): Check for leading dot on MY_DOMAIN.
6820 (ftp_getaddress): Check for empty, null or (null) domain.
6822 * url.c (get_urls_html): If this_url is NULL, the base must have a
6824 (parseurl): Use has_proto.
6826 * retr.c (retrieve_url): Warn when proxy is used with more than 20
6829 * url.c (mkstruct): Create the directory (calling mymkdir()) only
6830 if it is not already there.
6831 (has_proto): New function.
6832 (get_urls_html): Eliminate the remaining call to findurl -- use
6837 * main.c: Change -X to -x.
6839 * url.c (url_filename): Simplify creation of filename if
6840 prefix_files is set.
6841 (url_filename): Simplify everything. And I do mean *everything*.
6842 (mkstruct): Add dir_prefix before hostname.
6843 (path_simplify): Fixed a bug that caused writing outside the path
6844 string in case of "." and ".." path strings.
6846 1996-07-06 Hrvoje Niksic <hniksic@srce.hr>
6848 * init.c: Added --mirror.
6850 * main.c (main): Added -X to force saving of directory hierarchy.
6852 * ftp.c (ftp_retrieve_list): Added recursion depth counter.
6853 (ftp_retrieve_list): Check whether quota is exceeded.
6855 * url.c (get_urls_html): Skip leading blanks for absolute URIs.
6857 * http.c (gethttp): Use referer if present.
6859 * recur.c (recursive_retrieve): Set u->referer before calling
6862 * url.c (newurl): Use memset to nullify the struct members.
6863 (freeurl): Free the referer field too.
6865 * url.h: Added referer to urlinfo.
6867 * geturl.1: Updated the manual to document some of the new features.
6869 * utils.c (numdigit): Moved from url.c.
6871 * README: Rewritten.
6873 * config.h.in: Add the support for socks.
6875 * configure.in: Add the support for socks.
6877 * url.c (url_filename): If the dir_prefix is ".", work with just
6879 (url_filename): Do not look for .n extensions if timestamping if
6882 * retr.c (show_progress): Skip the over-abundant restval data, and
6883 print the rest of it with ',' instead of '.'.
6885 1996-07-05 Hrvoje Niksic <hniksic@srce.hr>
6887 * retr.c (show_progress): Changed second arg. to long (as it
6889 (show_progress): Moved to retr.c.
6890 (get_contents): Moved to retr.c.
6892 * version.c: Change version to 1.4b13.
6894 1996-07-05 Hrvoje Lacko <hlacko@fly.cc.fer.hr>
6896 * url.c (in_acclist): Would return after the first suffix.
6898 1996-07-04 Hrvoje Niksic <hniksic@srce.hr>
6900 * version.c: "Released" 1.4b12.
6902 * url.c (path_simplify): More kludgifications.
6903 (get_urls_html): Use new parameters for htmlfindurl.
6905 * html.c: Removed memorizing "parser states", since the new
6906 organization does not require them.
6908 * init.c (run_geturlrc): Use read_whole_line.
6910 * ftp-unix.c (ftp_parse_ls): Use read_whole_line.
6912 * recur.c (parse_robots): Use read_whole_line.
6914 * utils.c (read_whole_line): New function.
6916 * recur.c (tried_robots): Use add_slist/in_slist, *much* cleaner.
6918 * host.c (ngethostbyname): Call inet_addr just once. Yet to be
6919 tested on OSF and Ultrix.
6920 (add_hlist): New function.
6921 (free_hlist): New function.
6922 (search_host): New function.
6923 (search_address): New function.
6924 (realhost): Use search_host, search_address and add_hlist.
6925 (same_host): Replaced realloc() with strdupdelim(), made
6926 case-insensitive, fixed a memory leak.
6928 * html.c (ftp_index): Fixed tm_min and tm_sec to be tm_hour and
6929 tm_min, like intended.
6931 * version.c: Change user agent information to
6934 1996-07-03 Hrvoje Niksic <hniksic@srce.hr>
6936 * utils.c: Renamed nmalloc.c to utils.c, .h likewise.
6938 * url.c (acceptable): Always accept directories.
6940 * ftp-unix.c (ftp_parse_ls): Support brain-damaged "ls -F"-loving
6941 servers by stripping trailing @ from symlinks and trailing / from
6944 * ftp.c (ftp_loop): Debugged the "enhanced" heuristics. :-)
6946 * url.c (skip_url): Use toupper instead of UCASE.
6948 * host.c (sufmatch): Made it case-insensitive.
6950 * url.c (match_backwards_or_pattern): Fixed i == -1 to j == -1.
6951 (match_backwards): New function, instead of
6952 match_backwards_or_pattern.
6954 * recur.c (recursive_retrieve): Increased performance by
6955 introducing inl, which reduces number of calls to in_slist to only
6958 * ftp.c (ftp_loop): Enhanced the heuristics that decides which
6961 * main.c (printhelp): Removed the warranty stuff.
6963 1996-07-02 Hrvoje Niksic <hniksic@srce.hr>
6965 * url.c (add_slist): Simplify.
6966 (match_backwards_or_pattern): New function.
6967 (in_acclist): Use match_backwards_or_pattern.
6970 1996-06-30 Hrvoje Niksic <hniksic@srce.hr>
6972 * ftp.c (ftp_loop): Call ftp_index on empty file names, if not
6975 * html.c (ftp_index): Fixed to work. Beautified the output.
6977 * ftp.c (ftp_retrieve_glob): Another argument to control whether
6978 globbing is to be used.
6979 (ftp_retrieve_list): Compare the time-stamps of local and remote
6980 files to determine whether to download.
6982 1996-06-29 Hrvoje Niksic <hniksic@srce.hr>
6984 * ftp.c (rel_constr): New function.
6986 * retr.c (retrieve_from_file): Check for text/html before
6987 retrieving recursively.
6989 * main.c (main): Check whether the file is HTML before going into
6990 recursive HTML retrieving.
6992 * ftp.c (ftp_retrieve_list): Manage directories.
6993 (ftp_retrieve_glob): Pass all the file-types to ftp_retrieve_list.
6994 (ftp_1fl_loop): Fixed a bug that caused con->com to be incorrectly
6995 initialized, causing bugchecks in getftp to fail.
6997 * configure.in: Check for symlink.
6999 * ftp.c (ftp_retrieve_list): Added support for symlinks.
7001 * version.c: "Released" 1.4b10.
7003 * atotm.c (atotm): Redeclared as time_t.
7005 * init.c: New variable "timestamping".
7007 * main.c (main): New option 'N'.
7009 * http.c (hgetlocation): Case-insensitive match.
7010 (hgetmodified): New function.
7011 (http_loop): Implement time-stamping.
7013 1996-06-28 Hrvoje Niksic <hniksic@srce.hr>
7015 * version.c: Changed version to 1.4b10
7017 * atotm.c: New file, from phttpd.
7019 * options.h (struct options): New parameter timestamping.
7021 * version.c: 1.4b9 "released".
7023 * recur.c (recursive_retrieve): Used linked list (ulist) for
7024 faster storing of URLs.
7026 * url.c (get_urls_html): Removed the old kludge with comparing the
7027 outputs of htmlfindurl and findurl.
7028 (get_urls_html): Added better protocol support here.
7029 (create_hash): Removed, as well as add_hash and in_hash.
7030 (addslist): New function.
7033 * version.c: Released 1.4b8, changed version to b9.
7035 1996-06-27 Hrvoje Niksic <hniksic@srce.hr>
7037 * ftp.c (freefileinfo): New function.
7038 (delelement): New function.
7042 * ftp.c (ftp_loop): Use ccon.
7043 (ftp_retrieve_glob): Likewise.
7045 * ftp.h: Define ccon, to define status of control connection.
7047 * ftp.c (ftp_get_listing): New function.
7048 (ftp_retrieve_more): New function.
7049 (ftp_retrieve_glob): New function.
7051 1996-06-25 Hrvoje Niksic <hniksic@srce.hr>
7053 * configure.in: Removed the search for cuserid().
7055 * init.c (getmode): Renamed to getperms.
7057 1996-06-24 Hrvoje Niksic <hniksic@srce.hr>
7059 * version.c: New version.
7061 * main.c (hangup): New function, that handles hangup. Hangup
7062 signal now causes geturl to stop writing on stdout, and to write
7065 * ftp.c (getftp): "Released" 1.4b7.
7067 * html.c (htmlfindurl): Ignore everything inside <head>...</head>.
7068 (ftp_index): Use fileinfo/urlinfo.
7070 * ftp-unix.c (ftp_parse_ls): New function.
7071 (symperms): New function.
7073 * ftp.c (ftp_1fl_loop): New function, to handle 1-file loops.
7075 * retr.c (retrieve_url): Added FTP support.
7077 1996-06-23 Hrvoje Niksic <hniksic@srce.hr>
7079 * geturl.h: Removed NOTFTP2HTML enum.
7080 Added DO_LOGIN, DO_CWD and DO_LIST. LIST_ONLY is obsolete.
7082 * ftp.c (getftp): Resynched with urlinfo.
7083 (getftp): Removed HMTL-ization of index.html from getftp.
7085 * version.c: 1.4b6 "released".
7087 * options.h (options): New struct, to keep options in.
7089 * http.c (http_loop,gethttp): Synched with proxy.
7091 * retr.c (retrieve_url): Implemented proxy retrieval.
7093 * main.c (main): Use retrieve_from_file.
7095 1996-06-22 Hrvoje Niksic <hniksic@srce.hr>
7097 * retr.c (retrieve_from_file): New function.
7099 * url.c (parseurl): Modified to return URLOK if all OK. Protocol
7100 can be found in u->proto.
7102 * ftp.c (ftp_response): Fixed to accept multi-line responses as
7105 * recr.c (recursive_retrieve): Take newloc from retrieve_url.
7107 * url.c (mymkdir): Removed the file of the same name, if one
7109 (isfile): New function.
7110 (mkstruct): Fixed the '/' glitches.
7111 (path_simplify): Hacked to treat something/.. correctly.
7113 1996-06-21 Hrvoje Niksic <hniksic@srce.hr>
7115 * http.c (gethttp): Close the socket after error in headers.
7116 (http_loop): HEOF no longer a fatal header.
7118 * loop.c (retrieve_url): When dt is NULL, do not modify it. This
7119 simplifies the syntax of calling retrieve_url.
7121 * recr.c (recursive_retrieve): Modified to use get_urls_html.
7123 * url.c (get_urls_file): New function.
7124 (get_urls_html): New function.
7126 * recr.c (recursive_retrieve): Patched up to conform to the
7129 * http.c (gethttp): Synched with the rest...
7130 (gethttp): Treat only CONREFUSED specially, with connection
7133 * init.c,geturl.1,http.c (http_loop): Removed kill_error.
7135 1996-06-20 Hrvoje Niksic <hniksic@srce.hr>
7137 * http.c (http_loop): New function.
7139 * loop.c: Removed *lots* of stuff from retrieve_url.
7141 * url.c (parseurl): Changed to work with urlinfo. Integrated
7142 username finding and path parsing.
7143 (newurl): New function.
7144 (freeurl): New function.
7145 (mkstruct): Removed the old bogosities, made it urlinfo-compliant.
7146 (url_filename): Likewise.
7147 (path_simplify): Accept relative paths too.
7148 (opt_url): Made urlinfo-compliant, removed bogosities.
7149 (path_simplify): Expanded to accept relative paths.
7150 (str_url): A replacement for hide_url
7151 (decode_string): Fixed a bug that caused malfunctioning when
7152 encountering an illegal %.. combination.
7153 (opt_url): Removed the argument. Dot-optimizations are now default.
7155 * nmalloc.c (strdupdelim): New function.
7157 * url.h: Added the urlinfo structure
7159 1996-06-19 Hrvoje Niksic <hniksic@srce.hr>
7161 * url.c (hide_url): Thrown out the protocol assertion. Do not
7162 change the URL if the protocol if not recognized.
7163 (findurl): Put continue instead of break.
7165 1996-06-18 Hrvoje Niksic <hniksic@srce.hr>
7167 * sample.geturlrc: Changed the defaults to be commented out and
7168 harmless (previous defaults caused pains if copied to
7171 * http.c (gethttp): Print the HTTP request in debug mode.
7173 * connect.c (iread): Added EINTR check loop to select-ing
7174 too. EINTR is now correctly handled with select().
7178 1996-05-07 Hrvoje Niksic <hniksic@srce.hr>
7180 * host.c (same_host): Made the function a little bit more
7181 intelligent regarding diversified URL syntaxes.
7183 * url.c (skip_url): Spaces are now skipped after URL:
7185 * Released 1.3.1 with the patch to prevent crashing when sending
7186 NULL to robot* functions and the patch to compile "out of the box"
7189 * recr.c (recursive_retrieve): Added checking whether this_url is
7190 NULL when calling the robot functions.
7192 * ChangeLog: New file.