]> sjero.net Git - wget/blob - src/ChangeLog
[svn] Csaba's Watcom changes.
[wget] / src / ChangeLog
1 2000-12-18  Csaba Raduly  <csaba.raduly@sophos.com>
2
3         * sysdep.h: Include <malloc.h> and <io.h> under Watcom.
4
5 2000-12-31  Dan Harkless  <wget@harkless.org>
6
7         * ChangeLog: Since this flat file doesn't have multiple branches,
8         looking at the dates would make you think that things went into
9         1.6 that actually just went into the 1.7-dev branch.  Added "[Not
10         in 1.6 branch.]" where appropriate to clarify.
11         
12 2000-12-30  Dan Harkless  <wget@harkless.org>
13
14         * ftp.c, http.c:  Applied Hack Kampbjørn <hack@hackdata.com>'s
15         patch to deal with h_errno not being defined in netdb.h under Cygwin.
16
17         * version.c: Released Wget version 1.6.
18
19 2000-12-17  Igor Khristophorov  <igor@atdot.org>
20
21         * http.c (check_end): Fix test for '+' or '-'.
22
23 2000-12-17  Hrvoje Niksic  <hniksic@arsdigita.com>
24
25         * url.c (parseurl): Rename inner loop var from i to ind to avoid
26         clash with the function top-level-declared variable i.
27         (str_url): Likewise, rename inner-loop i to j.
28
29         * recur.c (parse_robots): Don't declare LEN at top of function.
30         (robots_match): Renamed parameter FORBIDDEN to avoid hiding of
31         global variable.
32
33         * main.c (main): Change erroneous use of bitwise and to logical.
34
35         * init.c (cmd_address): Don't heap-allocate `sin'; it can be on
36         the stack because it will be copied to closure.
37
38         Thanks to Csaba Raduly's run of PC-LINT over the sources.
39
40 2000-12-17  Hrvoje Niksic  <hniksic@arsdigita.com>
41
42         * http.c (basic_authentication_encode): Use xmalloc(), not
43         malloc().  Thanks to Csaba Raduly's run of PC-LINT over the
44         sources.
45
46 2000-12-17  Csaba Raduly  <csaba.raduly@sophos.com>
47
48         * sysdep.h: Test for __EMX__ rather than for EMXOS2 for OS/2
49         compilation.
50
51 2000-12-17  Hrvoje Niksic  <hniksic@arsdigita.com>
52
53         * mswindows.c: Include <errno.h>.
54
55         * gen_sslfunc.c: Include <errno.h>.  [Not in 1.6 branch.]
56
57         * ftp-basic.c: Don't attempt to declare errno or h_errno because
58         they're not used.
59
60         * main.c: Include <errno.h> because errno is used.
61
62         * ftp.c: Ditto.
63
64         * http.c: Include <netdb.h> for h_errno.
65
66 2000-12-13  Hrvoje Niksic  <hniksic@arsdigita.com>
67
68         * html-parse.c (advance_declaration): MSVC assert() chokes on
69         '\"'.  Use '"' instead.  [Not in 1.6 branch.]
70
71 2000-12-11  Hrvoje Niksic  <hniksic@arsdigita.com>
72
73         * utils.c (xfree_real): Removed.
74         (xfree_debug): Just call free().
75         [Not in 1.6 branch.]
76
77         * wget.h (xfree): Make it an alias for free.  [Not in 1.6 branch.]
78
79 2000-12-11  Hrvoje Niksic  <hniksic@arsdigita.com>
80
81         * http.c (http_loop): Furthermore, touch output_document only if
82         it is known to be an existing regular file.
83
84 2000-12-11  Hrvoje Niksic  <hniksic@arsdigita.com>
85
86         * ftp.c (ftp_retrieve_list): Ditto.
87
88         * http.c (http_loop): Touch output_document if that is used for
89         output.
90
91 2000-12-06  Hrvoje Niksic  <hniksic@arsdigita.com>
92
93         * http.c: Include gen_sslfunc.h after including Wget's headers.
94         (persistent_available_p): Needed coma before `int ssl'.
95         [Not in 1.6 branch.]
96
97 2000-12-06  Hrvoje Niksic  <hniksic@arsdigita.com>
98
99         * ftp.c (ftp_loop_internal): Ditto.
100
101         * http.c (http_loop): Use it.
102
103         * retr.c (sleep_between_retrievals): New function that handles the
104         logic of opt.wait and opt.waitretry.
105
106 2000-12-06  Hrvoje Niksic  <hniksic@arsdigita.com>
107
108         * rbuf.h: Implement only a single version of RBUF_READCHAR, using
109         rbuf_read_bufferful when the buffer is depleted.  [Not in 1.6 branch.]
110
111         * rbuf.c (rbuf_read_bufferful): New function.  [Not in 1.6 branch.]
112
113 2000-12-06  Hrvoje Niksic  <hniksic@arsdigita.com>
114
115         * gen_sslfunc.h: Use ansi2knr style function declarations.  [Not
116         in 1.6 branch.]
117
118         * gen_sslfunc.c: Reformat according to the GNU coding standards.
119         More should be done.  [Not in 1.6 branch.]
120
121         * http.c (persistent_available_p): Place the cheap SSL test nearer
122         the top of the function.
123         (CLOSE_FINISH, CLOSE_INVALIDATE): Define only one version of each.
124         [Not in 1.6 branch.]
125
126 2000-12-03  Christian Fraenkel <christian.fraenkel@gmx.net>
127
128         * Makefile.in: added gen_sslfunc object
129         * config.h.in: added HAVE_SSL define
130         * connect.c: changed select_fd from static int to int
131         * connect.h: ditto
132         * gen_sslfunc.h: New file
133         * gen_sslfunc.c: ditto
134         * http.c: added HTTPS fuctionality
135         * retrc.c: ditto
136         * url.c: ditto
137         * init.c: added opt.httpsproxy
138         * options.h: ditto
139         * rbuf.h: added alternate rbuf struct
140         * wget.h: added CONSSLERR
141         * rbuf.c: ditto
142
143         * http.c: Added HTTPS fuctionality.
144
145         * retrc.c: Ditto.
146
147         * url.c: Ditto.
148
149         * init.c: Added opt.httpsproxy.
150
151         * options.h: Ditto.
152
153         * rbuf.h: Added alternate rbuf struct.
154
155         * wget.h: Added CONSSLERR.
156
157         * rbuf.c: Ditto.
158
159         [All above not in 1.6 branch.]
160
161 2000-11-30  Jan Prikryl  <prikryl@cg.tuwien.ac.at>
162
163         * ftp-ls.c (ftp_parse_unix_ls): Added second parameter
164         "ignore_perms" to ignore file and directory permissions for
165         Windows NT FTP server listings.
166         (ftp_parse_winnt_ls): New function.
167         (ftp_parse_ls): Parses UNIX and Windows NT listings
168         separately. Simple heuristics for distinguishing between UNIX
169         and MS-DOS-like FTP listing provided by Windows NT FTP service.
170         [Not in 1.6 branch.]
171
172 2000-12-05  Hrvoje Niksic  <hniksic@arsdigita.com>
173
174         * url.c (init_unsafe_char_table): Reinstate space as an unsafe
175         char.  [Not in 1.6 branch.]
176
177 2000-11-29  John Summerfield  <summer@OS2.ami.com.au>
178
179         * netrc.c (parse_netrc): Get rid of line ending.  [Not in 1.6 branch.]
180
181 2000-11-25  Hrvoje Niksic  <hniksic@arsdigita.com>
182
183         * ftp.c (ftp_retrieve_list): Undo typo "fix" until resolution by
184         Dan.  [Not in 1.6 branch.]
185
186 2000-11-24  Karl Eichwalder  <ke@suse.de>
187
188         * main.c (print_help): Untabify.
189
190 2000-11-23  Hrvoje Niksic  <hniksic@arsdigita.com>
191
192         * utils.c (xrealloc_debug): Do the unregister/register thing only
193         if the pointer has actually changed.
194         (xmalloc_real): Declare `static' in DEBUG_MALLOC builds.
195         (xfree_real): Ditto.
196         (xrealloc_real): Ditto.
197         (xstrdup_real): Ditto.
198         [Not in 1.6 branch.]
199
200 2000-11-22  Hrvoje Niksic  <hniksic@arsdigita.com>
201
202         * ftp.c (getftp): ftp_getaddress() returns a malloc'ed copy of the
203         string; no need to strdup() it.
204         (getftp): Make pwd_len a local variable.  [Not in 1.6 branch.]
205         (ftp_loop): Free PWD before returning.  [Not in 1.6 branch.]
206
207         * init.c (cleanup): Free opt.ftp_pass only if it's non-NULL.
208
209 2000-11-22  Hrvoje Niksic  <hniksic@arsdigita.com>
210
211         * all: Use xfree() instead of free.  [Not in 1.6 branch.]
212
213         * utils.c (xfree): New function.  [Not in 1.6 branch.]
214
215 2000-11-21  Hrvoje Niksic  <hniksic@arsdigita.com>
216
217         * url.c (convert_links): HTML-quote the converted string.  [Not in
218         1.6 branch.]
219
220         * utils.c (html_quote_string): Move here from ftp-ls.c
221         (html_quote_string): Make non-static; declare in utils.h.
222         (html_quote_string): Convert SP to &#32;.
223         [Not in 1.6 branch.]
224
225 2000-11-21  Hrvoje Niksic  <hniksic@arsdigita.com>
226
227         * ftp.c (getftp): Reformat Jan's code according to GNU coding
228         standards; remove (debugging?) printf's; use '\0' for the ASCII
229         zero character.  Use alloca() instead of malloc() for
230         inter-function temporary allocations.
231         [Not in 1.6 branch.]
232
233 2000-11-18  Jan Prikryl  <prikryl@cg.tuwien.ac.at>
234
235         * ftpparse.c, ftpparse.h: New files.  [Not in 1.6 branch.]
236
237         * ftp-ls.c (ftp_parse_ls): Use ftp_parse_unix_ls for UNIX servers
238         only. Use ftp_parse_nonunix_ls otherwise.
239         (ftp_parse_nonunix_ls): Stub to the ftpparse library handling all
240         exotic FTP servers.
241         [Not in 1.6 branch.]
242
243         * ftp.h (stype): New enum, distinguishes UNIX, VMS, and "other"
244         FTP servers.  [Not in 1.6 branch.]
245
246         * ftp.c: New static wariables host_type, pwd, and pwd_len. 
247         (getftp): Support for VMS. Support for FTP servers that do not
248         place you in the root directory after login.
249         (ftp_retrieve_list): VMS is silent about the real file size, issue
250         a more appropriate message.
251         (ftp_get_listing): Pass host_type to ftp_parse_ls.
252         [Not in 1.6 branch.]
253
254         * ftp-basic.c (ftp_pwd, ftp_syst): New functions.  [Not in 1.6 branch.]
255
256 2000-11-21  Hrvoje Niksic  <hniksic@arsdigita.com>
257
258         * hash.c (hash_table_put): Don't overwrite deleted mappings.  [Not
259         in 1.6 branch.]
260
261 2000-11-21  Hrvoje Niksic  <hniksic@arsdigita.com>
262
263         * hash.c (find_mapping): New function.
264         (hash_table_get): Use it.
265         (hash_table_get_pair): Ditto.
266         (hash_table_exists): Ditto.
267         (hash_table_remove): Ditto.
268         (hash_table_remove): Really delete the entry if the mapping
269         following LOCATION is empty.
270         [Not in 1.6 branch.]
271
272         * utils.c (string_set_add): Check whether the element has existed
273         before.  [Not in 1.6 branch.]
274
275         * hash.c (hash_table_get_pair): New function.  [Not in 1.6 branch.]
276
277 2000-11-20  Hrvoje Niksic  <hniksic@arsdigita.com>
278
279         * http.c (http_process_type): Ignore trailing whitespace; use
280         strdupdelim().  [Not in 1.6 branch.]
281
282         * recur.c (recursive_retrieve): Use the new `convert' field.
283         (convert_all_links): Ditto.
284         (convert_all_links): Don't respect meta_disallow_follow.
285         [Not in 1.6 branch.]
286
287         * html-url.c (handle_link): Fill out link_relative_p and
288         link_complete_p.  [Not in 1.6 branch.]
289
290         * url.h (struct _urlpos): Make elements more readable.  [Not in
291         1.6 branch.]
292
293         * recur.c (recursive_retrieve): Call slist_prepend instead of
294         slist_append.
295         (convert_all_links): Call slist_nreverse before iterating through
296         urls_html.
297         [Not in 1.6 branch.]
298
299         * utils.c (slist_prepend): New function.
300         (slist_nreverse): Ditto.
301         [Not in 1.6 branch.]
302
303 2000-11-20  Hrvoje Niksic  <hniksic@arsdigita.com>
304
305         * http.c (check_end): Constify.
306
307 2000-11-20  Hrvoje Niksic  <hniksic@arsdigita.com>
308
309         * http.c (http_loop): If username and password are known, try the
310         `Basic' authentication scheme by default.  [Not in 1.6 branch.]
311
312         * connect.h: Declare test_socket_open.  [Not in 1.6 branch.]
313
314 2000-11-20  Hrvoje Niksic  <hniksic@arsdigita.com>
315
316         * version.c: Bump version to 1.7-dev.  [Not in 1.6 branch.]
317
318 2000-11-20  Hrvoje Niksic  <hniksic@arsdigita.com>
319
320         * http.c (gethttp): Don't use the return value of sprintf().
321         (gethttp): Inhibit keep-alive if opt.http_keep_alive is 0.
322         [Not in 1.6 branch.]
323
324 2000-11-20  Hrvoje Niksic  <hniksic@arsdigita.com>
325
326         * recur.c (recursive_retrieve): Print the "so we don't load"
327         debugging message only if we really don't load.  [Not in 1.6 branch.]
328
329         * http.c (gethttp): Inhibit keep-alive if proxy is being used.
330         (gethttp): Don't request keep-alive if keep-alive is inhibited.
331         [Not in 1.6 branch.]
332
333 2000-11-19  Hrvoje Niksic  <hniksic@arsdigita.com>
334
335         * http.c (gethttp): Make the HTTP persistent connections more
336         robust.  [Not in 1.6 branch.]
337
338 2000-11-19  Hrvoje Niksic  <hniksic@arsdigita.com>
339
340         * retr.c (get_contents): If use_expected, make sure that the
341         appropriate amount of data is being read.  [Not in 1.6 branch.]
342
343         * http.c (gethttp): Check for both `Keep-Alive: ...' and
344         `Connection: Keep-Alive'.  [Not in 1.6 branch.]
345
346         * wget.h (DEBUGP): Call debug_logprintf only if opt.debug is
347         turned on.  [Not in 1.6 branch.]
348
349 2000-11-19  Hrvoje Niksic  <hniksic@arsdigita.com>
350
351         * http.c (connection_available_p): Use it.  [Not in 1.6 branch.]
352
353         * connect.c (test_socket_open): New function.  [Not in 1.6 branch.]
354
355         * http.c (gethttp): Support persistent connections.  Based on the
356         ideas, and partly on code, by Sam Horrocks <sam@daemoninc.com>.
357         (register_persistent): New function.
358         (connection_available_p): Ditto.
359         (invalidate_connection): Ditto.
360         [Not in 1.6 branch.]
361
362 2000-11-19  Hrvoje Niksic  <hniksic@arsdigita.com>
363
364         * url.c (convert_links): Handle UREL2ABS case.  [Not in 1.6 branch.]
365
366         * recur.c (recursive_retrieve): Instead of the list
367         urls_downloaded, use hash tables dl_file_url_map and
368         dl_url_file_map.
369         (convert_all_links): Use them to retrieve data.
370         [Not in 1.6 branch.]
371
372         * host.c (clean_hosts): Free the hash tables.  [Not in 1.6 branch.]
373
374         * main.c (private_initialize): Call host_init().  [Not in 1.6 branch.]
375
376         * host.c (store_hostaddress): Use a saner, hash table-based data
377         model.
378         (realhost): Ditto.
379         (host_init): Initialize the hash tables.
380         [Not in 1.6 branch.]
381
382 2000-11-18  Hrvoje Niksic  <hniksic@arsdigita.com>
383
384         * utils.c (slist_append): Eviscerate NOSORT.  Hash tables are now
385         used for what the sorted slists used to be used for.
386         (slist_contains): Don't rely on the list being sorted.
387         (slist_append): Simplify the code.
388         [Not in 1.6 branch.]
389
390         * recur.c (recursive_cleanup): Use free_string_set.  [Not in 1.6
391         branch.]
392
393         * utils.c (string_set_add, string_set_exists, string_set_free):
394         New functions for easier freeing of hash tables whose keys are
395         strdup'ed strings.  [Not in 1.6 branch.]
396
397         * recur.c (recursive_retrieve): Use the hash table functions for
398         storing undesirable URLs.  [Not in 1.6 branch.]
399
400         * hash.c: New file.  [Not in 1.6 branch.]
401
402 2000-11-17  Hrvoje Niksic  <hniksic@arsdigita.com>
403
404         * main.c (private_initialize): Call url_init.
405         (main): Call private_initialize.
406         [Not in 1.6 branch.]
407
408         * url.c (unsafe_char_table): New table.
409         (UNSAFE_CHAR): Use it.
410         (init_unsafe_char_table): New function.
411         (url_init): New function; call init_unsafe_char_table.
412         [Not in 1.6 branch.]
413
414 2000-11-15  Hrvoje Niksic  <hniksic@arsdigita.com>
415
416         * html-url.c (handle_link): Handle HTML fragment identifiers.
417         [Not in 1.6 branch.]
418
419         * recur.c (recursive_retrieve): If norobot info is respected and
420         the file is specified not to be followed by robots, respect that.
421         [Not in 1.6 branch.]
422
423         * html-url.c (collect_tags_mapper): Handle <meta name=robots
424         content=X>.  For us the important cases are where X is NONE or
425         where X contains NOFOLLOW.
426         (get_urls_html): Propagate that information to the caller.
427         [Not in 1.6 branch.]
428
429 2000-11-13  Hrvoje Niksic  <hniksic@arsdigita.com>
430
431         * url.c (convert_links): Unlink the file we might be reading from
432         before writing to it.
433         (convert_links): Use alloca instead of malloc for
434         filename_plus_orig_suffix.
435         [Not in 1.6 branch.]
436
437 2000-11-10  Hrvoje Niksic  <hniksic@arsdigita.com>
438
439         * url.c (get_urls_file): Ditto.
440         (convert_links): Ditto.
441         [Not in 1.6 branch.]
442
443         * html-url.c (get_urls_html): Use read_file() instead of
444         load_file().  [Not in 1.6 branch.]
445
446         * utils.c (read_file): New function, instead of the old
447         load_file().
448         (read_file_free): Ditto.
449         [Not in 1.6 branch.]
450
451         * url.c (findurl): Search only for the supported protocols.
452         (convert_links): Use fwrite() when writing out a region of
453         characters.
454         [Not in 1.6 branch.]
455
456 2000-11-10  Hrvoje Niksic  <hniksic@arsdigita.com>
457
458         * ftp-ls.c: Move html_quote_string and ftp_index here.  [Not in
459         1.6 branch.]
460
461         * url.c: Remove get_urls_html, since that's now in html-url.c.
462         [Not in 1.6 branch.] 
463
464         * html-url.c: New file.  [Not in 1.6 branch.]
465
466         * html-parse.c: New file.  [Not in 1.6 branch.]
467
468 2000-11-16  Hrvoje Niksic  <hniksic@arsdigita.com>
469
470         * mswindows.h: Define snprintf and vsnprintf to _snprintf and
471         _vsnprintf respectively.
472
473 2000-11-15  Hrvoje Niksic  <hniksic@arsdigita.com>
474
475         * config.h.in: Do the _XOPEN_SOURCE and _SVID_SOURCE things only
476         on Linux.
477
478 2000-11-12  Hrvoje Niksic  <hniksic@arsdigita.com>
479
480         * host.c (realhost): Add HOST to the list with quality==0 only if
481         it wasn't already there.
482         Based on analysis by Lu Guohan <feng@public.bjnet.edu.cn>.
483
484 2000-11-10  Hrvoje Niksic  <hniksic@arsdigita.com>
485
486         * init.c (run_wgetrc): Don't bother killing off '\r' since
487         pars_line() skips whitespace at end of line anyway.
488         (parse_line): Oops, it didn't.  Now it does.
489
490         * recur.c (parse_robots): Ditto here.
491
492         * ftp-ls.c (ftp_parse_unix_ls): Kill off the newline character
493         manually because read_whole_line no longer does.
494
495         * utils.c (read_whole_line): Rewrite to: a) use less memory
496         (reallocates to needed size after work), b) work faster -->
497         fgets() instead of getc, c) be more correct --> doesn't kill the
498         newline character at the end of line.
499
500 2000-11-10  Hrvoje Niksic  <hniksic@arsdigita.com>
501
502         * init.c (comind): Initialize MAX to array size - 1.
503
504 2000-11-08  Hrvoje Niksic  <hniksic@arsdigita.com>
505
506         * url.c (construct): Changed last_slash[-1] to *(last_slash - 1).
507         Suggested by Edward J. Sabol.
508
509 2000-11-08  Hrvoje Niksic  <hniksic@arsdigita.com>
510
511         * url.c (construct): Handle the case where host name is not
512         followed by a slash.
513
514 2000-11-06  Hrvoje Niksic  <hniksic@arsdigita.com>
515
516         * init.c: commands[] need to be sorted!  ("base" wasn't.)
517
518 2000-11-05  Hrvoje Niksic  <hniksic@arsdigita.com>
519
520         * wget.h (DO_REALLOC_FROM_ALLOCA): Use braces to disambiguate
521         `if'.
522
523 2000-11-05  Hrvoje Niksic  <hniksic@arsdigita.com>
524
525         * url.c (construct): Insert unneeded initialization for the
526         compiler to shut up.
527
528         * config.h.in: Define _XOPEN_SOURCE to 500 to get the prototype
529         for strptime() (*duh*).  Define _SVID_SOURCE to get S_IFLNK which
530         otherwise gets lost when you define _XOPEN_SOURCE.
531
532         * utils.c (touch): Include the file name in the error message.
533         From Debian.
534
535 2000-11-05  Hrvoje Niksic  <hniksic@arsdigita.com>
536
537         * log.c (logvprintf): Use vsnprintf() in all cases.  If necessary,
538         resize the buffer to fit the formated message.  That way, messages
539         of arbitrary size may be printed.
540         (logvprintf): Use saved_append() to optionally log the last
541         several lines of output.
542         (logputs): Ditto.
543         (log_close): Adapt to new data structures.
544         (log_dump): Ditto.
545         (redirect_output): Print messages to stderr, not to stdout.
546
547         * log.c (saved_append_1): New function.  Replaces the old logging
548         system ("log all output until 10M characters") with a new, much
549         more reasonable one ("log last screenful of text").
550         (saved_append): New function; call saved_append_1.
551         (free_log_line): New function.
552
553 2000-11-05  Hrvoje Niksic  <hniksic@arsdigita.com>
554
555         * url.c (construct): Fix comment.
556         (find_last_char): Document.
557
558 2000-11-04  Hrvoje Niksic  <hniksic@arsdigita.com>
559
560         * snprintf.c: New file.
561
562 2000-11-03  Hrvoje Niksic  <hniksic@arsdigita.com>
563
564         * wget.h: If HAVE_STDARG_H is not defined, don't declare argument
565         types to logprintf() and debug_logprintf().
566
567 2000-11-02  Hrvoje Niksic  <hniksic@arsdigita.com>
568
569         * ftp.c (ftp_loop_internal): Hide the password from the URL when
570         printing non-verbose.  Problem spotted by Dariusz Mlynarczyk
571         <darekm@bydg.lomac.com.pl>.
572
573 2000-11-02  Junio Hamano  <junio@twinsun.com>
574
575         * ftp-basic.c (ftp_login): Make comparison case-insensitive.
576
577 2000-11-02  Tyler Riddle  <triddle@liquidmarket.com>
578
579         * http.c (known_authentication_scheme_p): Recognize NTML
580         authentication.
581         (create_authorization_line): Treat NTML the same as `Basic'.
582
583 2000-11-02  Hrvoje Niksic  <hniksic@arsdigita.com>
584
585         * retr.c (retrieve_url): Free url before returning.
586         (retrieve_url): Free mynewloc before returning.
587         Spotted by Mark A. Mankins <Mankins_Mark@prc.com>.
588
589 2000-11-02  Hrvoje Niksic  <hniksic@arsdigita.com>
590
591         * url.c (parseurl): Remove possible reading past the end of
592         sup_protos[].  Spotted by Mark A. Mankins <Mankins_Mark@prc.com>.
593
594 2000-11-01  Hrvoje Niksic  <hniksic@arsdigita.com>
595
596         * main.c (main): In case of opt.downloaded overflowing, print
597         <overflow> instead of a totally bogus random value.
598
599         * retr.c (retrieve_from_file): Ditto.
600
601         * recur.c (recursive_retrieve): Ditto.
602
603         * main.c (main): Ditto.
604
605         * http.c (http_loop): Ditto.
606
607         * ftp.c (ftp_loop_internal): Use downloaded_increase() instead of
608         `+=', and downloaded_exceeds_quota() instead of the simple-minded
609         check.
610         (ftp_retrieve_list): Ditto.
611         (ftp_retrieve_dirs): Ditto.
612         (ftp_retrieve_glob): Ditto.
613
614         * retr.c (downloaded_increase): New function.  Notice overflows of
615         opt.downloaded.
616         (downloaded_exceeds_quota): Make sure that opt.downloaded is not
617         used if it overflowed.
618
619         * options.h (struct options): New member downloaded_overflow.
620
621 2000-11-01  Hrvoje Niksic  <hniksic@arsdigita.com>
622
623         * wget.h (enum): Remove extra space after last enumeration.
624
625 2000-11-01  Hrvoje Niksic  <hniksic@arsdigita.com>
626
627         * main.c (main): Use legible_very_long() for printing
628         opt.downloaded.
629
630         * utils.c (legible_1): New function that operates on strings and
631         does the brunt of legible()'s work.
632         (legible): Use legible_1().
633         (legible_very_long): New function; dump the argument with
634         sprintf(), and call legible_1().
635
636         * options.h (struct options): Use VERY_LONG_TYPE for
637         opt.downloaded.
638
639         * sysdep.h (VERY_LONG_TYPE): Define it to have a 64-bit or greater
640         type.
641
642         * config.h.in: Make sure that SIZEOF_LONG and SIZEOF_LONG_LONG get
643         defined.  Define HAVE_LONG_LONG if long long is available.
644
645 2000-11-01  Hrvoje Niksic  <hniksic@arsdigita.com>
646
647         * utils.c (long_to_string): Update with a later, better version.
648
649 2000-11-01  Hrvoje Niksic  <hniksic@arsdigita.com>
650
651         * url.c (path_simplify_with_kludge): New function.
652         (path_simplify_with_kludge): Disable it.  Instead...
653         (parse_dir): ...make sure that at this point the right thing is
654         done, i.e. that "query" part of the URL (?...) is always assigned
655         to the file, never to the directory portion of the path.
656
657 2000-11-01  Hrvoje Niksic  <hniksic@arsdigita.com>
658
659         * retr.c (retrieve_url): Detect redirection cycles.
660
661 2000-11-01  Hrvoje Niksic  <hniksic@arsdigita.com>
662
663         * url.c (get_urls_html): Decode HTML entities using
664         html_decode_entities.
665
666         * html.c (htmlfindurl): Don't count the `#' in numeric entities
667         (&#NNN;) as an HTML fragemnt.
668         (html_decode_entities): New function.
669
670 2000-11-01  Hrvoje Niksic  <hniksic@arsdigita.com>
671
672         * html.c (htmlfindurl): Fix recognition of # HTML fragments.
673
674 2000-11-01  Hrvoje Niksic  <hniksic@arsdigita.com>
675
676         * url.c (construct): Rewritten for clarity.  Avoids the
677         unnecessary copying and stack-allocation the old version
678         performed.
679
680 2000-10-31  Hrvoje Niksic  <hniksic@arsdigita.com>
681
682         * ftp.c (getftp): Ditto.
683
684         * http.c (gethttp): Rewind the stream when retrying from scratch.
685
686 2000-10-31  Hrvoje Niksic  <hniksic@arsdigita.com>
687
688         * retr.c (retrieve_url): Use url_concat() to handle relative
689         redirections instead of /ad hoc/ code.
690
691         * url.c (url_concat): New function encapsulating weird
692         construct().
693         (urllen_http_hack): New function.
694         (construct): When constructing new URLs, recognize that `?' does
695         not form part of the file name in HTTP.
696
697 2000-10-13  Adrian Aichner  <adrian@xemacs.org>
698
699         * retr.c: Add msec timing support for WINDOWS.
700         * retr.c (reset_timer): GetSystemTime() on WINDOWS.
701         * retr.c (elapsed_time): Calculate delta time to msec on WINDOWS.
702
703 2000-10-27  Dan Harkless  <wget@harkless.org>
704
705         * retr.c (retrieve_url): Manually applied T. Bharath
706         <TBharath@responsenetworks.com>'s patch to get wget to grok
707         illegal relative URL redirects.  Reformatted and re-commented it.
708
709 2000-10-23  Dan Harkless  <wget@harkless.org>
710
711         * connect.c (make_connection and bindport): Manually applied Rob
712         Mayoff <mayoff@dqd.com>'s 1.5.3 patch to add --bind-address,
713         changing coding style to GNU's.
714
715         * ftp.c (ftp_loop_internal): --delete-after wasn't implemented for
716         files downloaded via FTP.  Per a comment, .listing files were not
717         counted towards number of bytes and files downloaded because they're 
718         deleted anyway.  Well, they aren't under -nr, so count them then.
719
720         * init.c: Manually applied Rob Mayoff's 1.5.3 patch to add
721         --bind-address, alphabetizing, changing coding style to GNU's,
722         commenting, and renaming cmd_ip_address() to cmd_address() to
723         imply hostnames also okay.
724                 
725         * main.c (main): --delete-after didn't delete the root of the
726         tree.  Ignore --convert-links if --delete-after was specified.
727         Manually applied Rob Mayoff's 1.5.3 patch to add --bind-address,
728         fixing duplicate use of added-since-1.5.3 case value.
729         (print_help): Clarified that --delete-after deletes local files.
730         Rob forgot to add a line for his new --bind-address option.
731                 
732         * options.h (struct options): Manually applied Rob Mayoff's patch
733         to add --bind-address (bind_address structure member).
734                 
735         * recur.c (recursive_retrieve): Improved comment; added DEBUGP().
736         Ignore --convert-links if --delete-after was specified.
737                 
738         * retr.c (retrieve_from_file): Just added a DEBUGP().
739                 
740 2000-10-19  Dan Harkless  <wget@harkless.org>
741
742         * ftp.c (ftp_loop_internal): downloaded_file() enumerators changed.
743         (getftp): Applied Piotr Sulecki <Piotr.Sulecki@ios.krakow.pl>'s
744         patch to work around FTP servers that incorrectly respond to the
745         "REST" command with the remaining size rather than the total file size.
746                 
747         * http.c (gethttp): Improved a comment and added code to tack on
748         ".html" to text/html files without that extension when -E specified.
749         (http_loop): Use new downloaded_file() enumerators and deal with
750         the case of gethttp() called xrealloc() on u->local.
751
752         * init.c (commands): Added new "htmlextension" command.
753         Also renamed John Daily's cmd_quad() to the more descriptive
754         cmd_lockable_boolean(), alpha-sorted the CMD_DECLARE()s and
755         removed duplicate cmd_boolean() declaration.
756
757         * main.c (print_help): Added my new -E / --html-extension option.
758         (main): Undocumented --email-address option previously used -E synonym.
759         Stole it away for the much more deserving --html-extension's use.
760
761         * options.h (struct options): Added html_extension field.
762
763         * url.c (convert_links): URL X that we saved as X.html locally due
764         to -E needs to be backed up as X.orig, not X.html.orig.  Added comments.
765         (downloaded_file): Now remembers if we added .html extension to a file.
766
767         * url.h (downloaded_file_t): Added extra enumerators to support above.
768         (downloaded_file): Now takes and returns a downloaded_file_t.
769
770         * wget.h (unnamed "dt" enum): Added ADDED_HTML_EXTENSION enumerator.
771         
772 2000-10-09  Dan Harkless  <wget@harkless.org>
773
774         * html.c (htmlfindurl): Added unneeded initialization to quiet warning.
775                 
776         * main.c (print_help): Clarified what --retr-symlinks does.
777         
778 2000-09-15  John Daily  <jdaily@cyberdude.com>
779
780         * init.c: Add support for "always" and "never" values to allow
781         .wgetrc to override commandline (useful e.g. with .pm files
782         calling `wget --passive-ftp' when your firewall doesn't allow that).
783
784         * ftp.c (getftp): passive_ftp is first option to support always/never.
785
786 2000-08-30  Dan Harkless  <wget@harkless.org>
787
788         * ftp.c (ftp_retrieve_list): Use new INFINITE_RECURSION #define.
789         
790         * html.c: htmlfindurl() now takes final `dash_p_leaf_HTML' parameter.
791         Wrapped some > 80-column lines.  When -p is specified and we're at a 
792         leaf node, do not traverse <A>, <AREA>, or <LINK> tags other than 
793         <LINK REL="stylesheet">.
794         
795         * html.h (htmlfindurl): Now takes final `dash_p_leaf_HTML' parameter.
796         
797         * init.c: Added new -p / --page-requisites / page_requisites option.
798
799         * main.c (print_help): Clarified that -l inf and -l 0 both allow
800         infinite recursion.  Changed the unhelpful --mirrior description
801         to simply give the options it's equivalent to.  Added new -p option.
802         (main): Added some comments; handle new -p / --page-requisites.
803         
804         * options.h (struct options): Added new page_requisites field.
805
806         * recur.c: Changed "URL-s" to "URLs" and "HTML-s" to "HTMLs".
807         Calculate and pass down new `dash_p_leaf_HTML' parameter to
808         get_urls_html().  Use new INFINITE_RECURSION #define.
809
810         * retr.c: Changed "URL-s" to "URLs".  get_urls_html() now takes
811         final `dash_p_leaf_HTML' parameter.
812
813         * url.c: get_urls_html() and htmlfindurl() now take final
814         `dash_p_leaf_HTML' parameter.
815
816         * url.h (get_urls_html): Now takes final `dash_p_leaf_HTML' parameter.
817
818         * wget.h: Added some comments and new INFINITE_RECURSION #define.
819         
820 2000-08-23  Dan Harkless  <wget@harkless.org>
821
822         * main.c (print_help): -B / --base was not mentioned.
823
824 2000-08-22  Dan Harkless  <wget@harkless.org>
825
826         * main.c (print_help): Modified -nc description to mention that it
827         also prevents the creation of multiple versions of the same file
828         with ".<number>" suffixes.
829
830 2000-07-14  Jan Prikryl  <prikryl@cg.tuwien.ac.at>
831
832         * retr.c (retrieve_url): Consistently strdup opt.referer when
833         setting u->referer.
834
835 2000-06-09  Dan Harkless  <wget@harkless.org>
836
837         * main.c (print_help): --help output for --waitretry was over 80 cols.
838
839 2000-06-09  Hrvoje Niksic  <hniksic@iskon.hr>
840
841         * url.c (encode_string): Fix comment.
842         Suggested by Herold Heiko <Heiko.Herold@previnet.it>.
843
844 2000-06-01  Const Kaplinsky  <const@ce.cctpu.edu.ru>
845
846         * ftp.c (ftp_retrieve_list): Change permissions only on plain
847         files.
848
849 2000-06-01  Hrvoje Niksic  <hniksic@iskon.hr>
850
851         * url.c (str_url): Print the port number only if it's different
852         from the default port number for that protocol.
853
854 2000-05-22  Dan Harkless  <wget@harkless.org>
855
856         * main.c (print_help): Added --help line for Damir Dzeko
857         <ddzeko@zesoi.fer.hr>'s until-now-undocumented --referer option.
858         Removed comments that --referer and --waitretry were undocumented.
859         Changed "`.wgetrc' command" to "`.wgetrc'-style command" on --help
860         line for --execute.
861
862 2000-05-18  Hrvoje Niksic  <hniksic@iskon.hr>
863
864         * ftp.c (getftp): Ditto.
865
866         * http.c (gethttp): Check for return value of fclose/fflush.
867
868 2000-04-12  Hrvoje Niksic  <hniksic@iskon.hr>
869
870         * host.c (store_hostaddress): Instead of shifting ADDR, start
871         copying from the correct address.
872
873 2000-04-12  Hrvoje Niksic  <hniksic@iskon.hr>
874
875         * http.c (gethttp): Don't free REQUEST -- it was allocated with
876         alloca().
877         Pointed out by Gisle Vanem <gvanem@eunet.no>.
878
879 2000-04-04  Dan Harkless  <wget@harkless.org>
880
881         * host.c (store_hostaddress): R. K. Owen's patch introduces a
882         "left shift count >= width of type" warning on 32-bit
883         architectures.  Got rid of it by tricking the compiler w/ a variable.
884         
885         * url.c (UNSAFE_CHAR): The macro didn't include all the illegal
886         characters per RFC1738, namely everything above '~'.  It also
887         generated a warning on OSes where char =~ unsigned char.  Fixed.
888         
889 1998-10-17  Hrvoje Niksic  <hniksic@srce.hr>
890
891         * http.c (http_process_type): Removed needless strdup(), a memory
892         leak.
893
894 1998-09-25  Hrvoje Niksic  <hniksic@srce.hr>
895
896         * html.c (htmlfindurl): Set PH to the first occurrence of `#'.
897
898 1998-09-25  Simon Munton  <simonm@m4data.co.uk>
899
900         * init.c (wgetrc_file_name): Don't free HOME under Windows.
901
902 1998-12-01  "R. K. Owen"  <rkowen@Nersc.GOV>
903
904         * host.c (store_hostaddress): Fix for big endian 64-bit machines.
905
906 1998-12-01  Hrvoje Niksic  <hniksic@srce.hr>
907
908         * url.c (UNSAFE_CHAR): New macro.
909         (contains_unsafe): Use it.
910         (encode_string): Ditto.
911
912 1998-12-01  Hrvoje Niksic  <hniksic@srce.hr>
913
914         * main.c (i18n_initialize): Use LC_MESSAGES only if available.
915
916 2000-03-31  Hrvoje Niksic  <hniksic@srce.hr>
917
918         * Use TOUPPER/TOLOWER.
919
920 1998-12-22  Alexander V. Lukyanov  <lav@yars.free.net>
921
922         * ftp-opie.c (btoe): Zero-terminate OSTORE.
923
924 2000-03-21  Hrvoje Niksic  <hniksic@iskon.hr>
925
926         * wget.h (DO_REALLOC_FROM_ALLOCA): Ditto.
927
928         * sysdep.h (ISALNUM): New macro.
929         (TOLOWER): Ditto.
930         (TOUPPER): Ditto.
931
932 2000-03-10  Dan Harkless  <wget@harkless.org>
933
934         * html.c (idmatch): Implemented checking of my new --follow-tags
935         and --ignore-tags options.
936         
937         * init.c (commands): Added comment reminding people adding new
938         entries doing allocation to add corresponding freeing in cleanup().
939         (commands): Added new followtags and ignoretags commands.
940         (cleanup): Free storage for new followtags and ignoretags.
941         
942         * main.c: Use of "comma-separated list" was random -- normalized
943         it.  Did some alphabetization.  Added comments pointing out
944         "Options without arguments" and "Options accepting an argument"
945         sections of long_options[].  Added new options --follow-tags and
946         -G / --ignore-tags.  Added comment that Damir's --referer is
947         currently undocumented.  Added comment that Heiko's --waitretry is
948         partially undocumented (mentioned in --help but not in
949         wget.texi).  Moved improperly sorted 24, 129, and 'G' cases.
950         
951         * options.h (struct options): Added new fields follow_tags and
952         ignore_tags. 
953         
954         * wget.h: Added "#define EQ 0" so we can say "strcmp(a, b) == EQ".
955         
956 2000-03-02  Dan Harkless  <wget@harkless.org>
957
958         * ftp.c (ftp_loop_internal): Heiko introduced "suggest explicit
959         braces to avoid ambiguous `else'" warnings.  Eliminated them.
960         
961         * http.c (gethttp): Dan Berger's query string patch is totally
962         bogus.  If you have two different URLs, gen_page.cgi?page1 and
963         get_page.cgi?page2, they'll both be saved as get_page.cgi and the
964         second will overwrite the first.  Also, parameters to implicit
965         CGIs, like "http://www.host.com/db/?2000-03-02" cause the URLs to
966         be printed with trailing garbage characters, and could seg fault.
967         Backing out the patch, which Dan B. informed me by email was just
968         a kludge to download StarOffice from Sun made necessary due to
969         wget's unconditional escaping of certain characters (room for an
970         option there?).
971         (http_loop): Heiko introduced "suggest explicit braces to avoid
972         ambiguous `else'" warnings.  Eliminated them.
973         
974         * main.c: Heiko's --wait / --waitretry backwards compatibility
975         code looks to have been totally untested -- automatic variable
976         'wr' was used without being initialized, and a long int was passed
977         into setval()'s char* val parameter.
978         
979         * recur.c (parse_robots): Applied Edward J. Sabol
980         <sabol@alderaan.gsfc.nasa.gov>'s patch for Guan Yang's reported
981         problem with "User-agent:<space>*<space>" lines in robots.txt.
982         
983         * url.c (parseurl, str_url): Removing Dan Berger's code (see
984         http.c above for explanation).
985         
986 1999-08-25  Heiko Herold  <Heiko.Herold@previnet.it>
987
988         * ftp.c: Respect new option waitretry.
989
990 2000-01-30  Damir Dzeko  <ddzeko@zesoi.fer.hr>
991
992         * http.c (gethttp): Send custom Referer, if required.
993
994 1999-09-24  Charles G Waldman  <cgw@fnal.gov>
995
996         * netrc.c (parse_netrc): Allow passwords to contain spaces.
997
998         * netrc.c (parse_netrc): New function.
999
1000 1999-09-17  Dan Berger  <dberger@ix.netcom.com>
1001
1002         * http.c (gethttp): Send it.
1003
1004         * url.c (parseurl): Detect query string in HTTP URL-s.
1005         (str_url): Print it.
1006
1007 2000-03-02  HIROSE Masaaki  <hirose31@t3.rim.or.jp>
1008
1009         * html.c (html_allow): Add <link href=...> and <script src=...>.
1010
1011 1999-05-02  andrew deryabin  <djsf@softhome.net>
1012
1013         * http.c (gethttp): Specify port in `Host' header only if it's
1014         different from 80.
1015
1016 1998-11-03  Edward J. Sabol  <sabol@alderaan.gsfc.nasa.gov>
1017
1018         * recur.c (recursive_retrieve): If a finite maximum depth is
1019         specified, and we're are already at that depth, don't download the
1020         HTML file for parsing.
1021
1022 2000-03-01  Dan Harkless  <wget@harkless.org>
1023
1024         * ftp.c (ftp_loop_internal): Call new downloaded_file() function,
1025         even though we don't do conversion on HTML files retrieved via
1026         FTP, so _current_ usage of downloaded_file() makes this call unneeded. 
1027         (ftp_retrieve_list): Added a comment saying where we need to
1028         stat() a .orig file if FTP'd HTML file conversion is ever implemented.
1029         (ftp_retrieve_list): "Local file '%s' is more recent," is sometimes
1030         a lie -- reworded as "Server file no newer than local file '%s' --".
1031         
1032         * http.c (http_loop): Fixed a typo and clarified a comment.
1033         (http_loop): When -K and -N are specified together, compare size
1034         and timestamp of server file X against local file X.orig (if
1035         extant) rather than converted local file X.
1036         (http_loop): "Local file '%s' is more recent," is sometimes a lie
1037         -- reworded as "Server file no newer than local file '%s' --".
1038         (http_loop): Call new downloaded_file() function to prevent
1039         wrongful overwriting of .orig file when -N is specified.
1040         
1041         * url.c (convert_links): When -K specified, only rename X to
1042         X.orig if downloaded_file() returns TRUE.  Otherwise when we skip
1043         file X due to -N, we clobber an X.orig from a previous invocation.
1044         (convert_links): Call the failsafe xstrdup(), not the real strdup().
1045         (convert_links): Added a note asking anyone who understands how
1046         multiple URLs can correspond to a single file to comment it.
1047         (downloaded_file): Added this new function.
1048         
1049         * url.h (downloaded_file): Added prototype for this new function
1050         as well as its downloaded_file_t enum type.
1051
1052         * wget.h (boolean): Added this new typedef and TRUE and FALSE #defines.
1053
1054 2000-02-29  Dan Harkless  <wget@harkless.org>
1055
1056         * version.c: Upped version to developer-only "1.5.3+dev".
1057
1058 2000-02-18  Dan Harkless  <wget@harkless.org>
1059
1060         * init.c (backup_converted): Added this new option.
1061
1062         * main.c (-K / --backup-converted): Added this new option.
1063
1064         * options.h (backup_converted): Added this new option.
1065
1066         * url.c (convert_links): When backup_converted is specified, save
1067         file X as X.orig before converting.
1068
1069         * url.h (urlpos): Fixed typo -- said "Rekative" instead of "Relative".
1070
1071 1998-09-21  Hrvoje Niksic  <hniksic@srce.hr>
1072
1073         * version.c: Wget 1.5.3 is released.
1074
1075 1998-09-21  Hrvoje Niksic  <hniksic@srce.hr>
1076
1077         * host.c (ftp_getaddress): Don't warn when reverse-lookup of local 
1078         address doesn't yield FQDN.
1079
1080 1998-09-21  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
1081
1082         * cmpt.c (strerror): Fix declaration of sys_errlist.
1083
1084 1998-09-11  Hrvoje Niksic  <hniksic@srce.hr>
1085
1086         * main.c (main): Don't use an array subscript as the first
1087         argument to STRDUP_ALLOCA.
1088         From Kaveh R. Ghazi.
1089
1090 1998-09-11  Szakacsits Szabolcs  <szaka@sienet.hu>
1091
1092         * html.c (htmlfindurl): Download table background.
1093
1094 1998-09-11  Hans Grobler  <grobh@conde.ee.sun.ac.za>
1095
1096         * init.c (parse_line): Would free *com before allocating it.
1097         (parse_line): Would free com instead of *com.
1098
1099 1998-09-10  Howard Gayle  <howard@fjst.com>
1100
1101         * url.c (get_urls_html): Would drop the last character of the
1102         link.
1103
1104 1998-09-10  Hrvoje Niksic  <hniksic@srce.hr>
1105
1106         * http.c (http_loop): Don't print status code if quiet.
1107
1108 1998-09-10  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
1109
1110         * log.c: Use <stdarg.h> only when __STDC__.
1111
1112 1998-09-10  Adam D. Moss  <adam@foxbox.org>
1113
1114         * html.c (htmlfindurl): Download <layer src=...>.
1115
1116 1998-09-10  Howard Gayle  <howard@fjst.com>
1117
1118         * ftp.c (ftp_retrieve_list): Don't update the time stamp of a file 
1119         not retrieved.
1120
1121 1998-06-27  Hrvoje Niksic  <hniksic@srce.hr>
1122
1123         * utils.c: Include <libc.h> on NeXT.
1124
1125 1998-06-26  Heinz Salzmann  <heinz.salzmann@intermetall.de>
1126
1127         * url.c (get_urls_html): Fix calculation of URL position.
1128
1129 1998-06-23  Hrvoje Niksic  <hniksic@srce.hr>
1130
1131         * version.c: Wget 1.5.2 is released.
1132
1133 1998-06-23  Dave Love  <d.love@dl.ac.uk>
1134
1135         * ftp.c, init.c, netrc.c: Include errno.h.
1136
1137         * http.c: Include errno.h and time header.
1138
1139         * Makefile.in (exext): Define.
1140         (install.bin, uninstall.bin): Use it.
1141
1142 1998-06-21  Hrvoje Niksic  <hniksic@srce.hr>
1143
1144         * http.c (http_loop): Don't attempt to compare local and remote
1145         sizes if the remote size is unknown.
1146
1147 1998-06-16  Hrvoje Niksic  <hniksic@srce.hr>
1148
1149         * url.c (get_urls_html): Use malloc() instead of alloca in the
1150         loop.
1151
1152 1998-06-13  Hrvoje Niksic  <hniksic@srce.hr>
1153
1154         * version.c: Wget 1.5.2-b4 is released.
1155
1156 1998-06-13  Hrvoje Niksic  <hniksic@srce.hr>
1157
1158         * url.c (get_urls_html): Ignore spaces before and after the URI.
1159
1160 1998-06-08  Wanderlei Antonio Cavassin  <cavassin@conectiva.com.br>
1161
1162         * ftp.c (getftp): Translate `done'.
1163
1164 1998-06-06  Hrvoje Niksic  <hniksic@srce.hr>
1165
1166         * version.c: Wget 1.5.2-b3 is released.
1167
1168 1998-06-06  Alexander Kourakos  <awk@bnt.com>
1169
1170         * init.c (cleanup): Close dfp, don't free it.
1171
1172 1998-06-06  Hrvoje Niksic  <hniksic@srce.hr>
1173
1174         * utils.c (make_directory): Twiddle.
1175
1176         * config.h.in: Added template for access().
1177
1178 1998-06-05  Mathieu Guillaume  <mat@cythere.com>
1179
1180         * html.c (htmlfindurl): Download <input src=...>
1181
1182 1998-06-03  Hrvoje Niksic  <hniksic@srce.hr>
1183
1184         * utils.c (file_exists_p): Use access() with two arguments.
1185
1186 1998-05-27  Martin Kraemer  <Martin.Kraemer@mch.sni.de>
1187
1188         * netrc.c (parse_netrc): Correct logic.
1189
1190 1998-05-27  Hrvoje Niksic  <hniksic@srce.hr>
1191
1192         * ftp.c (getftp): Added `break'; suggested by Lin Zhe Min
1193         <ljm@ljm.wownet.net>.
1194
1195 1998-05-24  Hrvoje Niksic  <hniksic@srce.hr>
1196
1197         * version.c: Wget 1.5.2-b2 is released.
1198
1199 1998-05-18  Juan Jose Rodriguez  <jcnsoft@jal1.telmex.net.mx>
1200
1201         * mswindows.h: Don't translate mkdir to _mkdir under Borland.
1202
1203 1998-05-17  Hrvoje Niksic  <hniksic@srce.hr>
1204
1205         * retr.c (elapsed_time): Return correct value when
1206         HAVE_GETTIMEOFDAY is undefined.
1207
1208 1998-05-13  Hrvoje Niksic  <hniksic@srce.hr>
1209
1210         * version.c: Wget 1.5.2-b1 is released.
1211
1212 1998-05-08  Hrvoje Niksic  <hniksic@srce.hr>
1213
1214         * getopt.c (_getopt_internal): Use exec_name instead of argv[0].
1215         (_getopt_internal): Don't translate `#if 0'-ed strings.
1216
1217 1998-05-06  Douglas E. Wegscheid  <wegscd@whirlpool.com>
1218
1219         * mswindows.c (ws_handler): Use fork_to_background().
1220
1221 1998-05-05  Hrvoje Niksic  <hniksic@srce.hr>
1222
1223         * version.c: Wget 1.5.1 is released.
1224
1225 1998-05-05  Hrvoje Niksic  <hniksic@srce.hr>
1226
1227         * http.c (parse_http_status_line): Avoid `minor' and `major'
1228         names.
1229
1230 1998-05-02  Hrvoje Niksic  <hniksic@srce.hr>
1231
1232         * utils.c (mkdirhier): Renamed to make_directory.
1233
1234 1998-05-01  Hrvoje Niksic  <hniksic@srce.hr>
1235
1236         * mswindows.c (fork_to_background): Define under Windows.
1237
1238         * utils.c (fork_to_background): New function.
1239
1240         * html.c (htmlfindurl): Removed rerdundant casts.
1241
1242 1998-05-01  Douglas E. Wegscheid  <wegscd@whirlpool.com>
1243
1244         * mswindows.c (ws_mypath): Cache the path.
1245
1246 1998-04-30  Douglas E. Wegscheid  <wegscd@whirlpool.com>
1247
1248         * ftp.h: Prefix enum ftype members with FT_.
1249
1250         * ftp-ls.c, ftp.c, html.h: Adjust accordingly.
1251
1252         * mswindows.h: Use stat under Borland, _stat under MSVC.
1253
1254 1998-04-28  Hrvoje Niksic  <hniksic@srce.hr>
1255
1256         * http.c (known_authentication_scheme_p): New function.
1257         (gethttp): Handle authorization more correctly.
1258
1259         * ftp-basic.h: Removed.
1260
1261         * cmpt.h: Removed.
1262
1263         * utils.c: Include <unistd.h> before <pwd.h>; needed under SunOS
1264         with gcc 2.8.
1265         (numdigit): Use `while' loop.
1266
1267         * http.c (create_authorization_line): Detect authentication
1268         schemes case-insensitively.
1269
1270         * http.c (extract_header_attr): Use strdupdelim().
1271         (digest_authentication_encode): Move declaration of local
1272         variables to smaller scope.
1273         (digest_authentication_encode): Reset REALM, OPAQUE and NONCE.
1274         (create_authorization_line): Detect authentication schemes
1275         case-insensitively.
1276
1277         * utils.c (touch): Constify.
1278
1279         * http.c (gethttp): Report a nicer error when no data is received.
1280
1281         * rbuf.h (RBUF_READCHAR): Ditto.
1282
1283         * ftp-basic.c (ftp_response): Use sizeof.
1284
1285 1998-04-27  Hrvoje Niksic  <hniksic@srce.hr>
1286
1287         * retr.c (print_percentage): EXPECTED is long, not int.
1288         (print_percentage): Use floating-point arithmetic to avoid
1289         overflow with large files' sizes multiplied with 100.
1290
1291 1998-04-27  Gregor Hoffleit  <flight@mathi.uni-heidelberg.de>
1292
1293         * config.h.in: Added pid_t stub.
1294
1295         * sysdep.h (S_ISREG): Moved here from mswindows.h (NeXT doesn't
1296         define it).
1297
1298 1998-04-20  Hrvoje Niksic  <hniksic@srce.hr>
1299
1300         * version.c: Wget 1.5.0 is released.
1301
1302 1998-04-18  Hrvoje Niksic  <hniksic@srce.hr>
1303
1304         * url.c (str_url): Ditto.
1305
1306         * ftp-basic.c (ftp_rest): Use new name.
1307
1308         * utils.c (long_to_string): Renamed from prnum().
1309
1310 1998-04-16  Hrvoje Niksic  <hniksic@srce.hr>
1311
1312         * version.c: Wget 1.5-b17 is released.
1313
1314 1998-04-08  Hrvoje Niksic  <hniksic@srce.hr>
1315
1316         * headers.c (header_get): New argument FLAGS.
1317
1318         * http.c (gethttp): If request is malformed, bail out of the
1319         header loop.
1320         (gethttp): Check for empty header *after* the status line checks.
1321         (gethttp): Disallow continuations for status line.
1322
1323 1998-04-08  Hrvoje Niksic  <hniksic@srce.hr>
1324
1325         * version.c: Wget 1.5-b16 is released.
1326
1327 1998-04-08  Hrvoje Niksic  <hniksic@srce.hr>
1328
1329         * init.c (commands): Renamed `always_rest' to `continue'.
1330
1331 1998-04-05  Hrvoje Niksic  <hniksic@srce.hr>
1332
1333         * all: Use it.
1334
1335         * log.c (logputs): New argument.
1336         (logvprintf): Ditto.
1337         (logprintf): Ditto.
1338
1339 1998-04-04  Hrvoje Niksic  <hniksic@srce.hr>
1340
1341         * http.c (http_atotm): Update comment.
1342
1343         * main.c (i18n_initialize): Set LC_MESSAGES, not LC_ALL.
1344
1345         * wget.h: Renamed ENABLED_NLS to HAVE_NLS.
1346
1347         * main.c (i18n_initialize): New function.
1348         (main): Use it.
1349
1350         * log.c: Include <unistd.h>.
1351
1352         * retr.c (show_progress): Cast alloca to char *.
1353
1354 1998-04-04  Hrvoje Niksic  <hniksic@srce.hr>
1355
1356         * version.c: Wget 1.5-b15 is released.
1357
1358 1998-04-04  Hrvoje Niksic  <hniksic@srce.hr>
1359
1360         * utils.h: Declare file_non_directory_p().
1361
1362 1998-04-03  Hrvoje Niksic  <hniksic@srce.hr>
1363
1364         * main.c (main): It's `tries', not `numtries' now.
1365
1366 1998-04-01  Hrvoje Niksic  <hniksic@srce.hr>
1367
1368         * init.c (getperms): Removed.
1369
1370 1998-04-01  Tim Charron  <tcharron@interlog.com>
1371
1372         * log.c (logvprintf): Don't use ARGS twice.
1373
1374 1998-04-01  John  <john@futuresguide.com>
1375
1376         * mswindows.c: Cleaned up.
1377
1378 1998-04-01  Hrvoje Niksic  <hniksic@srce.hr>
1379
1380         * version.c: Wget 1.5-b14 is released.
1381
1382 1998-04-01  Hrvoje Niksic  <hniksic@srce.hr>
1383
1384         * ftp-opie.c (STRLEN4): New macro.
1385         (btoe): Use it.
1386
1387 1998-04-01  Junio Hamano  <junio@twinsun.com>
1388
1389         * http.c: Document all the Digest functions.
1390
1391 1998-04-01  Hrvoje Niksic  <hniksic@srce.hr>
1392
1393         * utils.c (file_non_directory_p): Renamed from isfile().
1394
1395         * mswindows.h (S_ISREG): New macro, suggested by Tim Adam.
1396
1397 1998-03-31  Hrvoje Niksic  <hniksic@srce.hr>
1398
1399         * utils.c (mkdirhier): Use 0777 instead of opt.dirmode.
1400
1401         * init.c (cmd_spec_dotstyle): Use 48 dots per line for binary
1402         style.
1403         (cmd_permissions): Removed.
1404
1405         * config.h.in: Add template for WORDS_BIGENDIAN.
1406
1407 1998-03-31  Junio Hamano  <junio@twinsun.com>
1408
1409         * http.c (HEXD2asc): New macro.
1410         (dump_hash): Use it.
1411
1412 1998-03-31  Hrvoje Niksic  <hniksic@srce.hr>
1413
1414         * version.c: Wget 1.5-b13 is released.
1415
1416 1998-03-31  Hrvoje Niksic  <hniksic@srce.hr>
1417
1418         * main.c (main): Don't try to use `com'.
1419
1420 1998-03-30  Hrvoje Niksic  <hniksic@srce.hr>
1421
1422         * init.c (cmd_permissions): New function.
1423
1424 1998-03-30  Hrvoje Niksic  <hniksic@srce.hr>
1425
1426         * version.c: Wget 1.5-b12 is released.
1427
1428 1998-03-30  Hrvoje Niksic  <hniksic@srce.hr>
1429
1430         * init.c (commands): Renamed `numtries' to `tries'.
1431         (cmd_spec_debug): Removed.
1432         (home_dir): Under Windows, return `C:\' if HOME is undefined.
1433
1434 1998-03-29  Hrvoje Niksic  <hniksic@srce.hr>
1435
1436         * config.h.in: Define _XOPEN_SOURCE.
1437
1438         * init.c (check_user_specified_header): New function.
1439         (cmd_spec_header): Use it.
1440         (cmd_spec_useragent): New function.
1441
1442 1998-03-29  Hrvoje Niksic  <hniksic@srce.hr>
1443
1444         * version.c: Wget 1.5-b11 is released.
1445
1446 1998-03-28  Hrvoje Niksic  <hniksic@srce.hr>
1447
1448         * wget.h: Include <libintl.h> only if NLS is enabled.
1449
1450 1998-03-26  Hrvoje Niksic  <hniksic@srce.hr>
1451
1452         * options.h (struct options): Made `wait' a long.
1453         (struct options): Ditto for `timeout'.
1454
1455 1998-03-19  Hrvoje Niksic  <hniksic@srce.hr>
1456
1457         * utils.c (exists): Renamed to file_exists_p.
1458         (file_exists_p): Use access() if available.
1459
1460 1998-03-17  Hrvoje Niksic  <hniksic@srce.hr>
1461
1462         * utils.c (memfatal): Set save_log_p to 0 to avoid potential
1463         infloop.
1464
1465         * log.c: do_logging -> save_log_p.
1466
1467         * config.h.in: Added template for HAVE_VSNPRINTF.
1468
1469 1998-03-16  Hrvoje Niksic  <hniksic@srce.hr>
1470
1471         * init.c: Ditto.
1472
1473         * http.c: Protect declaration against non-ANSI compiler.
1474
1475         * log.c (logvprintf): Use vsnprintf() if available.
1476
1477         * getopt.c (main): Don't translate test stuff.
1478
1479 1998-03-16  Hrvoje Niksic  <hniksic@srce.hr>
1480
1481         * version.c: Wget 1.5-b10 is released.
1482
1483 1998-03-11  Hrvoje Niksic  <hniksic@srce.hr>
1484
1485         * ftp.c (getftp): Don't translate "CWD %s".
1486
1487         * wget.h (GCC_FORMAT_ATTR): Renamed from FORMAT_ATTR.
1488
1489 1998-03-07  Hrvoje Niksic  <hniksic@srce.hr>
1490
1491         * ftp-opie.c (btoe): Use memcpy() instead of strncat().
1492
1493         * log.c (logputs): New function.
1494         (logvprintf): Renamed from vlogmsg; use logputs().
1495
1496         * retr.c (show_progress): Print `[100%]' when the retrieval is
1497         finished.
1498
1499         * init.c (run_wgetrc): Use FILE, not PATH.
1500         (wgetrc_file_name): Ditto.
1501
1502 1998-03-07  Tim Adam  <tma@osa.com.au>
1503
1504         * recur.c (parse_robots): Correctly reset `entries' on empty
1505         disallow.
1506
1507 1998-03-07  Hrvoje Niksic  <hniksic@srce.hr>
1508
1509         * init.c (cmd_spec_debug): Use cmd_boolean().
1510
1511 1998-02-23  Hrvoje Niksic  <hniksic@srce.hr>
1512
1513         * http.c (gethttp): Create proxy-authorization correctly.
1514
1515 1998-02-22  Hrvoje Niksic  <hniksic@srce.hr>
1516
1517         * md5.c: Ditto.
1518
1519         * getopt.c: Use ANSI function definitions.
1520
1521         * ftp-opie.c: New file.
1522
1523         * options.h: Don't redefine EXTERN.
1524
1525         * init.c: Sort it correctly.
1526
1527 1998-02-22  Hrvoje Niksic  <hniksic@srce.hr>
1528
1529         * version.c: Wget 1.5-b9 is released.
1530
1531 1998-02-22  Hrvoje Niksic  <hniksic@srce.hr>
1532
1533         * recur.c (recursive_retrieve): Reset `first_time'.
1534
1535         * ftp.c (getftp): Added `default' clause to switches of uerr_t.
1536
1537         * rbuf.c (rbuf_peek): Simplified.
1538         (rbuf_flush): Use MINVAL.
1539
1540         * wget.h (MINVAL): Moved from url.h.
1541
1542         * rbuf.h (RBUF_FD): New macro.
1543
1544         * url.c (add_url): Add to the head of the list.
1545
1546         * ftp.c (ftp_retrieve_list): Set the permissions to downloaded
1547         file.
1548         (getftp): Set the default permissions to 0600.
1549
1550 1998-02-21  Hrvoje Niksic  <hniksic@srce.hr>
1551
1552         * url.c (get_urls_html): Ditto.
1553         (convert_links): Ditto.
1554
1555         * recur.c (parse_robots): Ditto.
1556
1557         * html.c (ftp_index): Ditto.
1558
1559         * ftp-ls.c (ftp_parse_unix_ls): Open file as binary.
1560
1561         * init.c (defaults): Initialize `opt' to zero via memset.
1562
1563         * http.c (digest_authentication_encode): goto considered harmful.
1564
1565 1998-02-19  Hrvoje Niksic  <hniksic@srce.hr>
1566
1567         * ftp.c (delelement): Simplify and fix leak.
1568
1569 1998-02-18  Hrvoje Niksic  <hniksic@srce.hr>
1570
1571         * http.c (dump_hash): Use HEXD2ASC instead of home-grown stuff.
1572
1573         * url.h (HEXD2ASC): Removed warning.
1574
1575         * init.c (comind): Use binary search.
1576         (commands): Reorganized.
1577         (setval): Ditto.
1578         (cmd_boolean): New function.
1579         (cmd_number): Ditto.
1580         (cmd_number_inf): Ditto.
1581         (cmd_string): Ditto.
1582         (cmd_vector): Ditto.
1583         (cmd_directory_vector): Ditto.
1584         (cmd_bytes): Ditto.
1585         (cmd_time): Ditto.
1586         (cmd_spec_debug): Ditto.
1587         (cmd_spec_dirmode): Ditto.
1588         (cmd_spec_dirstruct): Ditto.
1589         (cmd_spec_dotstyle): Ditto.
1590         (cmd_spec_header): Ditto.
1591         (cmd_spec_htmlify): Ditto.
1592         (cmd_spec_mirror): Ditto.
1593         (cmd_spec_outputdocument): Ditto.
1594         (cmd_spec_recursive): Ditto.
1595         (settime): Merged with cmd_time().
1596         (setbytes): Merged with cmd_bytes().
1597         (setonoff): Merged with cmd_boolean().
1598         (onoff): Ditto.
1599
1600 1998-02-17  Hrvoje Niksic  <hniksic@srce.hr>
1601
1602         * Makefile.in (distclean): Remove `config.h'.
1603
1604 1998-02-17  Hrvoje Niksic  <hniksic@srce.hr>
1605
1606         * version.c: Wget 1.5-b8 is released.
1607
1608 1998-02-17  Hrvoje Niksic  <hniksic@srce.hr>
1609
1610         * http.c (digest_authentication_encode): New function.
1611         (create_authorization_line): Use it.
1612         (dump_hash): New function.
1613         (digest_authentication_encode): Use it.
1614
1615         * fnmatch.c: Renamed from `mtch.c'.
1616
1617 1998-02-15  Karl Eichwalder  <ke@suse.de>
1618
1619         * main.c (main): Tag "Written by..." string as translatable.
1620
1621 1998-02-15  Hrvoje Niksic  <hniksic@srce.hr>
1622
1623         * wget.h (FREE_MAYBE): New macro.
1624
1625         * http.c (create_authorization_line): Don't use ANSI C string
1626         concatenation feature.
1627         (basic_authentication_encode): Use alloca() for temporary
1628         variables.
1629
1630         * recur.h: Ditto.
1631
1632         * http.c: Ditto.
1633
1634         * headers.h: Ditto.
1635
1636         * ftp-basic.c: Protect declaration against non-ANSI compiler.
1637
1638         * http.c (create_authorization_line): Cast `unsigned char *' to
1639         `char *' for sprintf, to shut up the noisy Digital Unix cc.
1640
1641 1998-02-15  Hrvoje Niksic  <hniksic@srce.hr>
1642
1643         * version.c: Wget 1.5-b7 is released.
1644
1645 1998-02-15  Hrvoje Niksic  <hniksic@srce.hr>
1646
1647         * cmpt.c (strstr): Synched with glibc-2.0.6.
1648
1649         * ftp-basic.c (calculate_skey_response): Ditto.
1650         (calculate_skey_response): Use alloca().
1651
1652         * http.c (create_authorization_line): Work with FSF's version of
1653         md5.c.
1654
1655         * md5.c: New file, from GNU libc.
1656
1657 1998-02-14  Hrvoje Niksic  <hniksic@srce.hr>
1658
1659         * url.h (URL_CLEANSE): Name the temporary variable more carefully.
1660
1661 1998-02-13  Hrvoje Niksic  <hniksic@srce.hr>
1662
1663         * http.c (basic_authentication_encode): New function, instead of
1664         the macro.
1665
1666 1998-02-13  Junio Hamano  <junio@twinsun.com>
1667
1668         * http.c: Add HTTP-DA support.
1669         * ftp-basic.c: Add Opie/S-key support.
1670         * config.h.in, Makefile.in: Add HTTP-DA and Opie/S-key support.
1671         * md5.c, md5.h: New files.
1672
1673 1998-02-13  Hrvoje Niksic  <hniksic@srce.hr>
1674
1675         * http.c (http_process_range): Renamed from hprocrange().
1676         (http_process_range): Parse the whole header.
1677
1678         * headers.c: New file.
1679         (header_process): New function.
1680         (header_get): Renamed from fetch_next_header.
1681
1682         * all: Include utils.h only where necessary.
1683
1684         * wget.h: Declare xmalloc(), xrealloc() and xstrdup() here.
1685
1686         * wget.h: Add provisions for dmalloc.
1687
1688 1998-02-12  Hrvoje Niksic  <hniksic@srce.hr>
1689
1690         * version.c: Wget 1.5-b6 is released.
1691
1692 1998-02-12  Hrvoje Niksic  <hniksic@srce.hr>
1693
1694         * ftp.c (ftp_loop): Determine `filename' more precisely.
1695
1696         * init.c (setval): Don't set `opt.quiet' if output-document is
1697         `-'.
1698
1699         * log.c (log_init): Print to STDERR instead of STDOUT.
1700         (vlogmsg): Use STDERR by default.
1701         (logflush): Ditto.
1702
1703 1998-02-11  Simon Josefsson  <jas@pdc.kth.se>
1704
1705         * host.c: Use addr_in again.
1706
1707 1998-02-08  Karl Eichwalder  <karl@suse.de>
1708
1709         * http.c (gethttp): Fixed typo.
1710
1711 1998-02-08  Hrvoje Niksic  <hniksic@srce.hr>
1712
1713         * version.c: Wget 1.5-b5 is released.
1714
1715 1998-02-08  Hrvoje Niksic  <hniksic@srce.hr>
1716
1717         * retr.c (show_progress): Use it.
1718
1719         * log.c (logflush): New function.
1720
1721         * wget.h: Utilize __attribute__ if on gcc.
1722
1723 1998-02-07  Hrvoje Niksic  <hniksic@srce.hr>
1724
1725         * http.c (base64_encode_line): New argument LENGTH.
1726         (BASIC_AUTHENTICATION_ENCODE): Use it.
1727         (BASIC_AUTHENTICATION_ENCODE): Take length of HEADER into account.
1728
1729         * main.c (main): Fixed fprintf() format mismatch.
1730
1731 1998-02-06  Hrvoje Niksic  <hniksic@srce.hr>
1732
1733         * version.c: Wget 1.5-b4 is released.
1734
1735 1998-02-03  Simon Josefsson  <jas@pdc.kth.se>
1736
1737         * host.c: use sockaddr_in instead of addr_in.
1738
1739 1998-02-04  Hrvoje Niksic  <hniksic@srce.hr>
1740
1741         * init.c (cleanup): Use it.
1742
1743         * recur.c (recursive_cleanup): New function.
1744
1745         * retr.c (retrieve_from_file): Ditto.
1746
1747         * main.c (main): Use it.
1748
1749         * recur.c (recursive_reset): New function.
1750
1751         * retr.c (retrieve_from_file): Ditto.
1752
1753         * main.c (main): Simplify call to recursive_retrieve().
1754
1755         * recur.c (recursive_retrieve): Removed FLAGS argument.
1756
1757         * http.c (gethttp): Changed call to iwrite().
1758
1759 1998-02-03  Hrvoje Niksic  <hniksic@srce.hr>
1760
1761         * url.c (get_urls_html): Ditto.
1762         (free_urlpos): Ditto.
1763         (mkstruct): Ditto.
1764         (construct): Ditto.
1765
1766         * retr.c (retrieve_url): Move declaration of local variables to
1767         smaller scope.
1768
1769         * url.c (urlproto): Use it.
1770         (parseurl): Ditto.
1771         (str_url): Ditto.
1772         (get_urls_html): Ditto.
1773
1774         * utils.h (ARRAY_SIZE): New macro.
1775
1776         * url.c (proto): Moved from url.h.
1777
1778         * url.h (URL_CLEANSE): Reformatted.
1779         (USE_PROXY_P): Renamed from USE_PROXY.
1780
1781         * ftp-basic.c: Adjust to the new interface of iwrite().
1782
1783         * ftp-basic.c (ftp_port): Use alloca().
1784
1785 1998-02-03  Hrvoje Niksic  <hniksic@srce.hr>
1786
1787         * version.c: Wget 1.5-b3 is released.
1788
1789         * host.c (ftp_getaddress): Don't print to stderr directly.
1790
1791         * init.c (setbytes): Support `g' for gigabytes.
1792         (cmdtype): New specification CTIME.
1793         (setval): Use it with settime().
1794         (commands): Use it for WAIT and TIMEOUT.
1795
1796 1998-02-02  Hrvoje Niksic  <hniksic@srce.hr>
1797
1798         * http.c (BASIC_AUTHENTICATION_ENCODE): New macro.
1799         (gethttp): Use it.
1800
1801         * utils.c (unique_name_1): Moved from url.c.
1802         (unique_name): Ditto.
1803
1804         * url.c (url_filename): Ditto.
1805
1806         * log.c (redirect_output): Changed call to unique_name().
1807
1808         * url.c (unique_name_1): Renamed from unique_name().
1809         (unique_name): Changed interface.
1810
1811         * init.c (enum cmdid): Moved from init.h.
1812         (cmdtype): Ditto.
1813         (struct cmd): Ditto.
1814
1815         * main.c (main): Use it.
1816         (main): Moved `--backups' to not have a short option.
1817
1818         * options.h (struct options): New member BACKGROUND.
1819
1820         * main.c (print_help): Rearranged.
1821         (main): New long options for -n* short options: --no-directories,
1822         --no-host-directories, --non-verbose, --no-host-lookup and
1823         --dont-remove-listing.
1824
1825 1998-02-01  Hrvoje Niksic  <hniksic@srce.hr>
1826
1827         * main.c (main): Use log_close().
1828
1829         * log.c: New variable LOGFP.
1830         (vlogmsg): Use it.
1831         (redirect_output): Don't open /dev/null; set LOGFP to stdin
1832         instead.
1833         (log_close): New function.
1834
1835         * options.h (struct options): Removed LFILE.
1836
1837         * log.c (log_enable): Removed.
1838
1839         * main.c (main): Use it.
1840
1841         * log.c (log_init): New function.
1842
1843         * url.c (get_urls_html): Removed needless assignment to BASE.
1844
1845         * host.c (add_hlist): Don't set CMP needlessly.
1846
1847         * utils.c (match_backwards): Ditto.
1848         (in_acclist): Ditto.
1849
1850         * url.c (findurl): Ditto.
1851
1852         * netrc.c (parse_netrc): Ditto.
1853
1854         * log.c (log_dump): Ditto.
1855
1856         * html.c (html_quote_string): Ditto.
1857
1858         * ftp-basic.c (ftp_request): Made static.
1859
1860         * connect.c: Made global variables static.
1861
1862         * url.c (construct): Ditto.
1863
1864         * init.c (init_path): Avoid assignment inside `if'-condition.
1865
1866         * ftp.c: Don't include in.h or winsock.h.
1867
1868         * ftp.c (ftp_loop): Use SZ.
1869
1870         * connect.c (bindport): Cast &addrlen to int *.
1871         (conaddr): Ditto.
1872
1873         * init.c (initialize): Don't use SYSTEM_WGETRC unconditionally.
1874
1875 1998-01-31  Hrvoje Niksic  <hniksic@srce.hr>
1876
1877         * ftp.c (getftp): Initialize opt.ftp_pass here.
1878         (ftp_retrieve_dirs): Use alloca().
1879
1880         * init.c (defaults): Don't initialize opt.ftp_pass.
1881
1882         * sysdep.h (S_ISLNK): Declare for OS/2; ditto for lstat.
1883         From Ivan F. Martinez <ivanfm@ecodigit.com.br>.
1884
1885 1998-01-31  Hrvoje Niksic  <hniksic@srce.hr>
1886
1887         * recur.c (parse_robots): Check for comments more correctly.
1888
1889         * host.c (ftp_getaddress): Use STRDUP_ALLOCA.
1890         (ftp_getaddress): Add diagnostics when reverse-lookup yields only
1891         hostname.
1892
1893 1998-01-31  Hrvoje Niksic  <hniksic@srce.hr>
1894
1895         * version.c: Wget 1.5-b2 is released.
1896
1897         * netrc.c (NETRC_FILE_NAME): Moved from netrc.h.
1898
1899         * utils.c (proclist): Pass FNM_PATHNAME to fnmatch().
1900
1901         * ftp-basic.c (ftp_pasv): Avoid unnecessary casting to unsigned
1902         char.
1903
1904         * log.c: Don't attempt to hide arguments from ansi2knr.
1905
1906         * cmpt.c: Synched strptime() and mktime() with glibc-2.0.6.
1907
1908         * ansi2knr.c: Use a later version, from fileutils-3.16l alpha.
1909
1910         * ftp.c (getftp): Ditto.
1911
1912         * http.c (gethttp): Use it.
1913
1914         * retr.c (get_contents): New argument EXPECTED; pass it to
1915         show_progress().
1916         (show_progress): New argument EXPECTED; use it to display
1917         percentages.
1918
1919         * init.c (setval): Ditto.
1920
1921         * http.c (gethttp): Ditto.
1922         (http_loop): Ditto.
1923
1924         * ftp.c (getftp): Ditto.
1925         (ftp_loop_internal): Ditto.
1926
1927         * ftp-ls.c (ftp_parse_unix_ls): Use abort() instead of assert(0).
1928
1929         * sysdep.h (CLOSE): Simplify; use DEBUGP.
1930
1931         * netrc.c (search_netrc): Use alloca().
1932
1933         * init.c (defaults): Initialize no_flush.
1934
1935         * log.c (vlogmsg): Don't flush if no_flush.
1936
1937         * options.h (struct options): New variable no_flush.
1938
1939         * main.c (main): Don't play games with buffering.
1940
1941         * log.c (vlogmsg): Flush the output after every message.
1942
1943 1998-01-31  Hrvoje Niksic  <hniksic@srce.hr>
1944
1945         * init.c (parse_line): Ditto.
1946
1947         * url.c (get_urls_html): Ditto.
1948
1949         * main.c (main): Don't cast to unsigned char.
1950
1951         * init.c (run_wgetrc): Don't cast to unsigned char.
1952         (parse_line): Accept char instead of unsigned char.
1953
1954         * html.c (htmlfindurl): Use char instead of unsigned char.
1955
1956         * all: Use them.
1957
1958         * sysdep.h: Add wrappers to ctype macros to make them
1959         eight-bit-clean:
1960
1961 1998-01-30  Hrvoje Niksic  <hniksic@srce.hr>
1962
1963         * html.c (htmlfindurl): Download <img lowsrc=...>
1964
1965         * main.c (main): Ignore SIGPIPE.
1966
1967         * connect.c (select_fd): New argument WRITEP.
1968         (iwrite): Call select_fd().
1969
1970 1997-02-27  Fila Kolodny <fila@ibi.com>
1971
1972         * ftp.c (ftp_retrieve_list): If retrieving symlink and the proper
1973         one already exists, just skip it.
1974
1975 1998-01-30  Hrvoje Niksic  <hniksic@srce.hr>
1976
1977         * http.c (gethttp): Cosmetic changes.
1978
1979         * http.c (check_end): Allow `+D...' instead of `GMT'.
1980         From Fabrizio Pollastri <pollastri@cstv.to.cnr.it>.
1981
1982         * url.c (process_ftp_type): New function.
1983         (parseurl): Use it.
1984
1985         * connect.c (iwrite): Allow writing in a few chunks.
1986         (bindport): Made SRV static, so addr can point to it.
1987         (select_fd): Removed HPUX kludge.
1988
1989         * host.c (free_hlist): Incorporated into clean_hosts().
1990
1991 1998-01-29  Hrvoje Niksic  <hniksic@srce.hr>
1992
1993         * host.c (hlist): Made static.
1994         (search_address): Cosmetic change.
1995
1996 1998-01-29  Hrvoje Niksic  <hniksic@srce.hr>
1997
1998         * version.c: Wget v1.5-b1 is released.
1999
2000         * http.c (hgetlen): Use sizeof() to get the header length.
2001         (hgetrange): Ditto.
2002         (hgettype): Ditto.
2003         (hgetlocation): Ditto.
2004         (hgetmodified): Ditto.
2005         (haccepts_none): Ditto.
2006
2007         * main.c (main): Updated `--version' and `--help' output, as per
2008         Francois Pinard's suggestions.
2009
2010         * main.c: Include locale.h; call setlocale(), bindtextdomain() and 
2011         textdomain().
2012
2013         * config.h.in: Define stubs for I18N3.
2014
2015         * wget.h: Include libintl.h.
2016
2017 1998-01-28  Hrvoje Niksic  <hniksic@srce.hr>
2018
2019         * url.c (mkstruct): Check for opt.cut_dirs.
2020         (mkstruct): alloca()-te more, xmalloc() less.
2021
2022         * utils.c (load_file): Check for ferror().
2023
2024         * url.c (get_urls_file): Close only the files we opened.
2025         (get_urls_html): Ditto.
2026         (count_slashes): New function.
2027
2028         * http.h: Removed.
2029
2030         * http.c (gethttp): Respect username and password provided by
2031         proxy URL.
2032         (base64_encode_line): Write into an existing buffer instead of
2033         malloc-ing a new one.
2034         (struct http_stat): Moved from http.h
2035
2036         * retr.c (retrieve_url): Free SUF.
2037
2038         * all: Removed lots of unnecessary .h dependencies.
2039
2040         * html.c (global_state): Made static.
2041
2042         * utils.h (ALLOCA_ARRAY): New macro.
2043
2044         * main.c (main): New option `--cut-dirs'.
2045
2046         * url.c (construct): Use alloca() for T.
2047
2048         * utils.c (mkdirhier): Use STRDUP_ALLOCA.
2049
2050         * host.c (_host_t): Moved from host.h.
2051         (struct host): Renamed from _host_t.
2052         (store_hostaddress): Use STRDUP_ALLOCA for INET_S.
2053         (realhost): Ditto.
2054
2055         * host.h: Don't include url.h.
2056
2057         * ftp.c (LIST_FILENAME): Moved from ftp.h.
2058
2059         * init.c (DEFAULT_FTP_ACCT): Moved from ftp.h.
2060
2061         * main.c (main): Enable log if the output goes to a TTY.
2062
2063         * connect.h: Removed unused constant `BACKLOG'.
2064
2065         * config.h.in: Check for isatty().
2066
2067         * Makefile.in (LINK): Use CFLAGS when linking.
2068
2069 1998-01-27  Hrvoje Niksic  <hniksic@srce.hr>
2070
2071         * mswindows.c (ws_hangup): Use redirect_output().
2072
2073         * main.c (redirect_output_signal): New function; use
2074         redirect_output().
2075
2076         * log.c (redirect_output): New function, based on hangup(), which
2077         is deleted.
2078
2079         * log.c (vlogmsg): New function.
2080
2081         * wget.h (DEBUGP): Use debug_logmsg().
2082
2083         * main.c (hangup): Use it.
2084
2085         * log.c (log_dump): New function.
2086
2087         * utils.h (DO_REALLOC): Use `long' for various sizes.
2088
2089         * http.c (hskip_lws): Use `while', for clarity.
2090         (HTTP_DYNAMIC_LINE_BUFFER): New constant.
2091         (fetch_next_header): Use it instead of DYNAMIC_LINE_BUFFER.
2092
2093         * ftp-basic.c (FTP_DYNAMIC_LINE_BUFFER): New constant.
2094         (ftp_response): Use it instead of DYNAMIC_LINE_BUFFER.
2095
2096         * utils.c (DYNAMIC_LINE_BUFFER): Moved from utils.c.
2097         (LEGIBLE_SEPARATOR): Ditto.
2098         (FILE_BUFFER_SIZE): Ditto.
2099
2100         * retr.c (BUFFER_SIZE): Moved from retr.h.
2101
2102         * log.c: New file.
2103         (logmsg): Moved from utils.c.
2104         (debug_logmsg): New function.
2105
2106         * mswindows.h: Include it here.
2107
2108         * init.c: Ditto.
2109
2110         * utils.c: Don't include <windows.h>.
2111
2112 1998-01-25  Hrvoje Niksic  <hniksic@srce.hr>
2113
2114         * host.c (ftp_getaddress): Ditto.
2115
2116         * main.c (main): Use it.
2117
2118         * utils.h (STRDUP_ALLOCA): New macro.
2119
2120         * init.c: Prepend `wget: ' to error messages printed on stderr.
2121
2122         * utils.c (mkdirhier): Renamed from mymkdir.
2123         (touch): Renamed from my_touch.
2124         (pwd_cuserid): Renamed from my_cuserid().
2125
2126 1998-01-24  Andy Eskilsson  <andy.eskilsson@telelogic.se>
2127
2128         * utils.c (accdir): Process wildcards.
2129         (proclist): New function.
2130         (accdir): Use it to avoid code repetition.
2131
2132 1998-01-24  Hrvoje Niksic  <hniksic@srce.hr>
2133
2134         * recur.c (parse_robots): Respect opt.useragent; use alloca().
2135
2136         * http.c (gethttp): Construct useragent accordingly.
2137
2138         * version.c: Changed version string to numbers-only.
2139
2140         * main.c (print_help): List all the options.
2141
2142         * mswindows.c (windows_main_junk): Initialize argv0 here.
2143
2144 1998-01-24  Karl Heuer  <kwzh@gnu.org>
2145
2146         * netrc.c (search_netrc): Initialize `l' only after processing
2147         netrc.
2148
2149         * main.c (main): Don't trap SIGHUP if it's being ignored.
2150
2151 1998-01-24  Hrvoje Niksic  <hniksic@srce.hr>
2152
2153         * all: Use logmsg().
2154
2155         * utils.c (time_str): Moved from retr.c.
2156         (logmsg): New function.
2157         (logmsg_noflush): Ditto.
2158
2159         * rbuf.c: New file, moved buf_* functions here.
2160
2161         * ftp.c (ftp_expected_bytes): Moved from ftp-basic.c.
2162
2163         * ftp-basic.c (ftp_rest): Use prnum().
2164
2165         * ftp-basic.c: Ditto.
2166
2167         * ftp.c: Use the new reading functions and macros.
2168
2169         * retr.c (buf_initialize): New function.
2170         (buf_initialized_p): Ditto.
2171         (buf_uninitialize): Ditto.
2172         (buf_fd): Ditto.
2173
2174         * http.c (fetch_next_header): Use the BUF_READCHAR macro for
2175         efficiency.
2176         (gethttp): Use alloca() where appropriate.
2177
2178         * retr.c (buf_readchar): Use it.
2179         (buf_peek): Use rstreams.
2180
2181         * retr.h (BUF_READCHAR): New macro.
2182
2183         * init.c (home_dir): Rewritten for clarity.
2184         (init_path): Ditto.
2185
2186         * mswindows.c (ws_backgnd): Made static.
2187         (read_registry): Ditto.
2188         (ws_cleanup): Ditto.
2189         (ws_handler): Ditto.
2190
2191 1998-01-23  Hrvoje Niksic  <hniksic@srce.hr>
2192
2193         * alloca.c: New file.
2194
2195         * Makefile.in (ALLOCA): Define.
2196
2197         * mswindows.c (ws_help): Constify.
2198         (ws_help): Use alloca.
2199
2200         * mswindows.c: Reformat.
2201
2202         * all: Added _(...) annotations for I18N snarfing and translation.
2203
2204         * host.c (ftp_getaddress): Nuke SYSINFO.
2205         (ftp_getaddress): Don't use getdomainname().
2206         (ftp_getaddress): Use uname(), where available.
2207
2208         * http.c (gethttp): Protect a stray fprintf().
2209
2210         * init.c (settime): New function.
2211         (setval): Treat WAIT specially, allowing suffixes like `m' for
2212         minutes, etc.
2213
2214 1998-01-21  Hrvoje Niksic  <hniksic@srce.hr>
2215
2216         * url.c (get_urls_html): Use alloca() for TEMP.
2217
2218 1998-01-21  Jordan Mendelson  <jordy@wserv.com>
2219
2220         * url.c (rotate_backups): New function.
2221
2222         * http.c (gethttp): Ditto.
2223
2224         * ftp.c (getftp): Rotate backups.
2225
2226 1997-12-18  Hrvoje Niksic  <hniksic@srce.hr>
2227
2228         * all: Renamed nmalloc(), nrealloc() and nstrdup() to xmalloc(),
2229         xrealloc() and xstrdup().  Use the new functions.
2230
2231         * url.c (decode_string): Made static.
2232         (has_proto): Ditto.
2233         (parse_dir): Ditto.
2234         (parse_uname): Ditto.
2235         (mkstruct): Ditto.
2236         (construct): Ditto.
2237         (construct_relative): Ditto.
2238
2239         * retr.c (show_progress): Made static.
2240
2241         * recur.c (robots_url): Made static.
2242         (retrieve_robots): Ditto.
2243         (parse_robots): Ditto.
2244         (robots_match): Ditto.
2245
2246         * main.h: Removed.
2247
2248         * main.c (printhelp): Made static.
2249         (hangup): Ditto.
2250
2251         * init.c (comind): Made static.
2252         (defaults): Ditto.
2253         (init_path): Ditto.
2254         (run_wgetrc): Ditto.
2255         (onoff): Ditto.
2256         (setonoff): Ditto.
2257         (setnum): Ditto.
2258         (myatoi): Ditto.
2259         (getperms): Ditto.
2260         (setbytes): Ditto.
2261
2262         * http.c (fetch_next_header): Made static.
2263         (hparsestatline): Ditto.
2264         (hskip_lws): Ditto.
2265         (hgetlen): Ditto.
2266         (hgetrange): Ditto.
2267         (hgettype): Ditto.
2268         (hgetlocation): Ditto.
2269         (hgetmodified): Ditto.
2270         (haccepts_none): Ditto.
2271         (gethttp): Ditto.
2272         (base64_encode_line): Ditto.
2273         (mktime_from_utc): Ditto.
2274         (http_atotm): Ditto.
2275
2276         * html.c (idmatch): Made static.
2277
2278         * host.c (search_host): Made static.
2279         (search_address): Ditto.
2280         (free_hlist): Ditto.
2281
2282         * ftp.c (getftp): Made static.
2283         (ftp_loop_internal): Ditto.
2284         (ftp_get_listing): Ditto.
2285         (ftp_retrieve_list): Ditto.
2286         (ftp_retrieve_dirs): Ditto.
2287         (ftp_retrieve_glob): Ditto.
2288         (freefileinfo): Ditto.
2289         (delelement): Ditto.
2290
2291         * ftp-ls.c (symperms): Made static.
2292         (ftp_parse_unix_ls): Ditto.
2293
2294         * connect.c (select_fd): Made static.
2295
2296         * utils.c (xmalloc): Renamed from nmalloc.
2297         (xrealloc): Renamed from nrealloc.
2298         (xstrdup): Renamed from nstrdup.
2299
2300         * getopt.c (exchange): Use alloca.
2301
2302         * mswindows.c (mycuserid): Use strncpy.
2303
2304         * New files mswindows.c, mswindows.h, sysdep.h.  winjunk.c,
2305         systhings.h, windecl.h and winjunk.h removed.
2306
2307         * mswindows.c (sleep): New function.
2308
2309         * utils.c: Include <windows.h> under Windows.
2310
2311 1997-06-12  Darko Budor  <dbudor@zesoi.fer.hr>
2312
2313         * url.h (URL_UNSAFE): Change default under Windows.
2314
2315         * retr.c (retrieve_from_file): Respect opt.delete_after.
2316
2317         * main.c (main): Call ws_help on Windows.
2318
2319         * winjunk.c (windows_main_junk): New function.
2320
2321         * main.c (main): Junk-process argv[0].
2322
2323         * http.c (mktime_from_utc): Return -1 if mktime failed.
2324
2325         * http.c (http_loop): Ditto.
2326
2327         * ftp.c (ftp_loop_internal): Change title on Windows when using a
2328         new URL.
2329
2330         * winjunk.c (getdomainname): Lots of functions.
2331
2332 1997-06-12  Hrvoje Niksic  <hniksic@srce.hr>
2333
2334         * cmpt.c (strptime_internal): Handle years more correctly for
2335         `%y'.
2336
2337 1997-06-09  Mike Thomas <mthomas@reality.ctron.com>
2338
2339         * http.c (gethttp): Allocate enough space for
2340         `Proxy-Authorization' header.
2341
2342 1997-05-10  Hrvoje Niksic  <hniksic@srce.hr>
2343
2344         * version.c: Wget/1.4.5 is released.
2345
2346 1997-05-10  Hrvoje Niksic  <hniksic@srce.hr>
2347
2348         * retr.c (get_contents): Check return value of fwrite more
2349         carefully.
2350
2351 1997-03-30  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
2352
2353         * cmpt.c (strptime_internal) [case 'Y']: Always subtract 1900 from
2354         year, regardless of century.
2355
2356 1997-03-30  Hrvoje Niksic  <hniksic@srce.hr>
2357
2358         * utils.c (isfile): Use `lstat' instead of `stat'.
2359
2360 1997-03-29  Hrvoje Niksic  <hniksic@srce.hr>
2361
2362         * utils.c (numdigit): Use explicit test.
2363
2364 1997-03-21  Hrvoje Niksic  <hniksic@srce.hr>
2365
2366         * http.c (http_loop): Always use `url_filename' to get u->local.
2367
2368 1997-03-20  Hrvoje Niksic  <hniksic@srce.hr>
2369
2370         * url.c: Recognize https.
2371
2372 1997-03-13  Hrvoje Niksic  <hniksic@srce.hr>
2373
2374         * recur.c (recursive_retrieve): Lowercase just the host name.
2375
2376 1997-03-09  Hrvoje Niksic  <hniksic@srce.hr>
2377
2378         * url.c (get_urls_file): Use the correct test.
2379         (get_urls_html): Ditto.
2380
2381 1997-03-07  Hrvoje Niksic  <hniksic@srce.hr>
2382
2383         * connect.c: Reverted addrlen to int.
2384
2385         * init.c (parse_line): Check for -1 instead of NONE.
2386
2387         * version.c: Changed version to 1.4.5.
2388
2389 1997-02-17  Hrvoje Niksic  <hniksic@srce.hr>
2390
2391         * init.c: New option netrc.
2392         (initialize): Don't parse .netrc.
2393
2394         * cmpt.c (recursive): Return rp.
2395         (strptime_internal): Match the long strings first, the abbreviated
2396         second.
2397
2398 1997-02-16  Hrvoje Niksic  <hniksic@srce.hr>
2399
2400         * http.c (check_end): New function.
2401         (http_atotm): Use it.
2402  
2403 1997-02-13  gilles Cedoc  <gilles@cedocar.fr>
2404
2405         * http.c (gethttp): Use them.
2406
2407         * init.c: New options proxy_user and proxy_passwd.
2408
2409 1997-02-14  Hrvoje Niksic  <hniksic@srce.hr>
2410
2411         * ftp.c (ftp_retrieve_list): Create links even if not relative.
2412
2413 1997-02-10  Hrvoje Niksic  <hniksic@srce.hr>
2414
2415         * recur.c (recursive_retrieve): Lowercase the host name, if the
2416         URL is not "optimized".
2417
2418         * host.c (realhost): Return l->hostname, even if it matches with
2419         host.
2420
2421 1997-02-10  Marin Purgar  <pmc@asgard.hr>
2422
2423         * connect.c: Make addrlen size_t instead of int.
2424         (conaddr): Ditto.
2425
2426 1997-02-09  Gregor Hoffleit  <flight@mathi.uni-heidelberg.DE>
2427
2428         * systhings.h: Define S_ISLNK on NeXT too.
2429
2430 1997-02-09  Hrvoje Niksic  <hniksic@srce.hr>
2431
2432         * version.c: Released 1.4.3.
2433
2434         * url.c: Futher update to list of protostrings.
2435         (skip_proto): Skip `//' correctly for FTP and HTTP.
2436
2437         * url.c (get_urls_html): Handle bogus `http:' things a little
2438         different.
2439
2440         * main.c (main): Removed `follow-ftp' from `f'.
2441         (main): Dumped the `prefix-files' and `file-prefix' options and
2442         features; old and bogus.
2443         (main): Exit on failed setval() in `-e'.
2444
2445         * http.c (fetch_next_header): Use it to detect header continuation
2446         correctly.
2447
2448         * retr.c (buf_peek): New function.
2449
2450 1997-02-08  Hrvoje Niksic  <hniksic@srce.hr>
2451
2452         * wget.h: Include time.h and stuff.
2453
2454 1997-02-08  Roger Beeman  <beeman@cisco.com>
2455
2456         * ftp.c: Include <time.h>
2457
2458 1997-02-07  Hrvoje Niksic  <hniksic@srce.hr>
2459
2460         * url.c (findurl): Would read over buffer limits.
2461
2462 1997-02-06  Hrvoje Niksic  <hniksic@srce.hr>
2463
2464         * ftp-ls.c (ftp_parse_unix_ls): Allow spaces in file names.
2465
2466 1997-02-05  Hrvoje Niksic  <hniksic@srce.hr>
2467
2468         * http.c (http_atotm): Initialize tm.is_dst.
2469
2470 1997-02-02  Hrvoje Niksic  <hniksic@srce.hr>
2471
2472         * http.c (gethttp): Don't print the number of retrieved headers.
2473
2474         * main.c (main): New option `--no-clobber', alias for `-nc'.
2475
2476         * url.c: Recognize `https://'.
2477
2478 1997-02-01  Hrvoje Niksic  <hniksic@srce.hr>
2479
2480         * host.c (herrmsg): Don't use h_errno.
2481
2482 1997-01-30  Hrvoje Niksic  <hniksic@srce.hr>
2483
2484         * host.c (accept_domain): Use it.
2485
2486         * main.c (main): New option `--exclude-domains'.
2487
2488         * retr.c (retrieve_url): Use it.
2489         (retrieve_url): Bail out when an URL is redirecting to itself.
2490
2491         * url.c (url_equal): New function.
2492
2493 1997-01-29  Hrvoje Niksic  <hniksic@srce.hr>
2494
2495         * connect.c: Include arpa/inet.h instead of arpa/nameser.h.
2496
2497         * http.c (mk_utc_time): New function.
2498         (http_atotm): Use it; handle time zones correctly.
2499
2500 1997-01-28  Hrvoje Niksic  <hniksic@srce.hr>
2501
2502         * http.c: Ditto.
2503
2504         * ftp-basic.c: Use it instead of WRITE.
2505
2506         * connect.c (iwrite): New function.
2507
2508 1997-01-27  Hrvoje Niksic  <hniksic@srce.hr>
2509
2510         * cmpt.c (mktime): New function.
2511
2512         * netrc.c: Include <sys/types.h>.
2513
2514         * main.c (main): Wouldn't recognize --spider.
2515
2516         * retr.c (rate): Use `B', `KB' and `MB'.
2517         (reset_timer,elapsed_time): Moved from utils.c.
2518
2519         * ftp.c (ftp_retrieve_list): Ditto.
2520
2521         * http.c (http_loop): Don't touch the file if opt.dfp.
2522
2523 1997-01-24  Hrvoje Niksic  <hniksic@srce.hr>
2524
2525         * cmpt.c: New file.
2526
2527         * ftp.c (ftp_retrieve_glob): New argument semantics.
2528         (ftp_retrieve_dirs): Use it.
2529         (ftp_loop): Ditto.
2530
2531         * html.c (htmlfindurl): Recognize `'' as the quote char.
2532
2533 1997-01-23  Hrvoje Niksic  <hniksic@srce.hr>
2534
2535         * ftp.c (ftp_loop_internal): Use it.
2536
2537         * utils.c (remove_link): New function.
2538
2539 1997-01-22  Hrvoje Niksic  <hniksic@srce.hr>
2540
2541         * retr.c (retrieve_url): Require STRICT redirection URL.
2542
2543         * url.c (parseurl): New argument STRICT.
2544
2545         * http.c (hparsestatline): Be a little-bit less strict about
2546         status line format.
2547
2548 1997-01-21  Hrvoje Niksic  <hniksic@srce.hr>
2549
2550         * http.c (gethttp): Use it.
2551
2552         * main.c (main): Don't use '<digit>' as options.
2553
2554         * init.c: New option ignore_length.
2555
2556         * http.c (gethttp): Ditto.
2557         (http_loop): Check for redirection without Location:.
2558         (gethttp): Don't print Length unless RETROKF.
2559
2560         * ftp.c (getftp): Use it.
2561
2562         * url.c (mkalldirs): New function.
2563
2564         * utils.c (mymkdir): Don't check for existing non-directory.
2565
2566         * url.c (mkstruct): Don't create the directory.
2567
2568 1997-01-20  Hrvoje Niksic  <hniksic@srce.hr>
2569
2570         * init.c (setval): Removed NO_RECURSION checks.
2571
2572 1997-01-19  Hrvoje Niksic  <hniksic@srce.hr>
2573
2574         * version.c: "Released" 1.4.3-pre2.
2575
2576         * recur.c (recursive_retrieve): Bypass host checking only if URL
2577         is ftp AND parent URL is not ftp.
2578
2579         * ftp-basic.c (ftp_request): Print out Turtle Power.
2580
2581         * ftp.c (ftp_loop): Call ftp_retrieve_glob with 0 if there's no
2582         wildcard.
2583         (ftp_retrieve_glob): Call ftp_loop_internal even on empty list, if
2584         not glob.
2585
2586         * http.c (gethttp): Be a little bit smarter about status codes.
2587
2588         * recur.c (recursive_retrieve): Always reset opt.recursive when
2589         dealing with FTP.
2590
2591 1997-01-18  Hrvoje Niksic  <hniksic@srce.hr>
2592
2593         * retr.c (retrieve_url): New variable location_changed; use it for
2594         tests instead of mynewloc.
2595         (retrieve_url): Allow heuristic adding of html.
2596
2597         * url.c (url_filename): Don't use the `%' in Windows file names.
2598
2599         * http.c (http_loop): Always time-stamp the local file.
2600
2601         * http.c (http_loop): Ditto.
2602
2603         * ftp.c (ftp_retrieve_list): Use it.
2604
2605         * utils.c (my_touch): New function.
2606
2607         * ftp.c (ftp_retrieve_list): Use #ifdef HAVE_STRUCT_UTIMBUF
2608         instead of #ifndef NeXT.
2609
2610         * utils.c (strptime): New version, by Ulrich Drepper.
2611
2612 1997-01-17  Hrvoje Niksic  <hniksic@srce.hr>
2613
2614         * http.c (haccepts_none): Renamed from `haccepts_bytes'.
2615         (gethttp): If haccepts_none(), disable ACCEPTRANGES.
2616         (http_loop): Would remove ACCEPTRANGES.
2617
2618         * ftp.c (getftp): Call ftp_list with NULL.
2619
2620 1997-01-15  Hrvoje Niksic  <hniksic@srce.hr>
2621
2622         * html.c (ftp_index): Don't print minutes and seconds if we don't
2623         know them; beautify the output.
2624
2625         * ftp.c (getftp): Don't close the socket on FTPNSFOD.
2626
2627 1997-01-14  Hrvoje Niksic  <hniksic@srce.hr>
2628
2629         * utils.c (strptime): New function.
2630         (strptime): Don't use get_alt_number.
2631         (strptime): Don't use locale.
2632         (match_string): Made it a function.
2633
2634 1997-01-12  Hrvoje Niksic  <hniksic@srce.hr>
2635
2636         * http.c (http_atotm): New function.
2637         (http_loop): Use it.
2638
2639         * atotm.c: Removed from the distribution.
2640
2641         * http.c (base64_encode_line): Rewrite.
2642
2643 1997-01-09  Hrvoje Niksic  <hniksic@srce.hr>
2644
2645         * ftp.c (getftp): Use ftp_expected_bytes; print size.
2646
2647         * ftp-basic.c (ftp_response): Use ftp_last_respline.
2648         (ftp_expected_bytes): New function.
2649
2650         * ftp.c (getftp): Print the unauthoritative file length.
2651
2652         * ftp-ls.c: Renamed from ftp-unix.c.
2653         (ftp_parse_ls): Moved from ftp.c.
2654         (ftp_parse_unix_ls): Recognize seconds in time spec.
2655         (ftp_parse_unix_ls): Recognize year-less dates of the previous
2656         year.
2657
2658 1997-01-08  Hrvoje Niksic  <hniksic@srce.hr>
2659
2660         * ftp-basic.c: Don't declare errno if #defined.
2661
2662         * host.c (ftp_getaddress): Check for sysinfo legally.
2663
2664 1997-01-08  Darko Budor  <dbudor@diana.zems.fer.hr>
2665
2666         * connect.c (iread): Use READ.
2667
2668 1996-12-23  Hrvoje Niksic  <hniksic@srce.hr>
2669
2670         * url.c: Recognize finger, rlogin, tn3270, mid and cid as valid
2671         schemes.
2672
2673 1996-12-22  Hrvoje Niksic  <hniksic@srce.hr>
2674
2675         * host.c (ftp_getaddress): Allow `.' in hostname.
2676
2677 1996-12-26  Darko Budor <dbudor@zems.fer.hr>
2678
2679         * wget.h: READ and WRITE macros for use instead of read and write
2680         on sockets, grep READ *.c, grep WRITE *.c
2681
2682         * wsstartup.c: new file - startup for winsock
2683
2684         * wsstartup.h: new file
2685
2686         * win32decl.h: new file - fixup for <errno.h> and winsock trouble
2687
2688         * configure.bat: Configure utility for MSVC
2689
2690         * src/Makefile.ms,config.h.ms: new files for use with MSVC 4.x
2691
2692 1996-12-22  Hrvoje Niksic  <hniksic@srce.hr>
2693
2694         * version.c: Released 1.4.3-pre.
2695
2696         * utils.c (prnum): Accept long.
2697         (legible): Use prnum().
2698
2699         * connect.c (make_connection): Accept port as short.
2700         (bindport): Ditto.
2701
2702         * http.c (gethttp): Use search_netrc.
2703
2704 1996-12-21  Hrvoje Niksic  <hniksic@srce.hr>
2705
2706         * ftp.c (getftp): Use search_netrc.
2707
2708         * netrc.c (free_netrc): New function.
2709
2710         * init.c (home_dir): New function.
2711
2712         * url.c (convert_links): Allow REL2ABS changes.
2713
2714 1996-12-21  Gordon Matzigkeit  <gord@gnu.ai.mit.edu>
2715
2716         * netrc.c: New file.
2717         (parse_netrc, maybe_add_to_list): New functions.
2718
2719 1996-12-17  Hrvoje Niksic  <hniksic@srce.hr>
2720
2721         * retr.c (retrieve_url): Reset opt.recursion before calling
2722         ftp_loop if it is reached through newloc.
2723
2724         * init.c (run_wgetrc): Print the wgetrc path too, when reporting
2725         error; don't use "Syntax error", since we don't know if it is
2726         really a syntax error.
2727
2728 1996-12-16  Hrvoje Niksic  <hniksic@srce.hr>
2729
2730         * utils.c (acceptable): Extract the filename part of the path.
2731
2732         * recur.c (recursive_retrieve): Call acceptable() with the right
2733         argument; would bug out on wildcards.
2734
2735         * init.c (parse_line): Likewise.
2736
2737         * html.c (htmlfindurl): Cast to char * when calling stuff.
2738
2739 1996-12-15  Hrvoje Niksic  <hniksic@srce.hr>
2740
2741         * ftp.c (getftp): Use ftp_pasv.
2742
2743         * ftp-basic.c (ftp_request): Accept NULL value.
2744         (ftp_pasv): New function.
2745
2746         * options.h (struct options): Add passive FTP option.
2747
2748 1996-12-15  Hrvoje Niksic  <hniksic@srce.hr>
2749
2750         * url.c (parseurl): Debug output.
2751
2752         * utils.c (path_simplify): New one, adapted from bash's
2753         canonicalize_pathname().
2754
2755 1996-12-14  Hrvoje Niksic  <hniksic@srce.hr>
2756
2757         * ftp.c (getftp): Don't discard the buffer.
2758
2759         * retr.c (get_contents): New parameter nobuf.
2760
2761 1996-12-13  Shawn McHorse  <riffraff@txdirect.net>
2762
2763         * html.c (htmlfindurl): Recognize <meta contents="d; URL=...".
2764
2765         * init.c (setval): Strip the trailing slashes on CVECDIR.
2766
2767 1996-12-13  Hrvoje Niksic  <hniksic@srce.hr>
2768
2769         * init.c: Make excludes and includes under CVECDIR instead of
2770         CVEC.
2771
2772 1996-12-13  Shawn McHorse  <riffraff@txdirect.net>
2773
2774         * url.c (get_urls_html): Skip "http:".
2775
2776 1996-12-13  Hrvoje Niksic  <hniksic@srce.hr>
2777
2778         * utils.c (strcasecmp): From glibc.
2779         (strncasecmp): Also.
2780         (strstr): Also.
2781
2782         * url.c: Added javascript: to the list of URLs prefixes.
2783
2784 1996-12-12  Shawn McHorse  <riffraff@txdirect.net>
2785
2786         * recur.c (retrieve_robots): Print the warning message only if
2787         verbose.
2788
2789 1996-12-12  Gregor Hoffleit  <flight@mathi.uni-heidelberg.DE>
2790
2791         * ftp.c (ftp_retrieve_list): Use NeXT old utime interface.
2792
2793 1996-12-12  Hrvoje Niksic  <hniksic@srce.hr>
2794
2795         * systhings.h: New file.
2796
2797         * ../configure.in: Check for utime.h
2798
2799         * ftp.c: Check whether we have unistd.h.
2800
2801 1996-11-27  Hrvoje Niksic  <hniksic@srce.hr>
2802
2803         * recur.c (recursive_retrieve): Send the canonical URL as referer.
2804         (recursive_retrieve): Call get_urls_html with the canonical URL.
2805
2806 1996-12-13  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
2807
2808         * (configure.in, config.h.in, src/Makefile.in, src/*.[ch]): Add
2809         ansi2knr support for compilers which don't support ANSI style
2810         function prototypes and signatures.
2811
2812         * (aclocal.m4, src/ansi2knr.c, src/ansi2knr.1): New files.
2813
2814 1996-11-26  Hrvoje Niksic  <hniksic@srce.hr>
2815
2816         * url.c: Use it; Recognize paths ending with "." and ".." as
2817         directories.
2818         (url_filename): Append .n whenever file exists and could be a
2819         directory.
2820
2821         * url.h (ISDDOT): New macro.
2822
2823         * init.c (parse_line): Use unsigned char.
2824
2825         * url.c (get_urls_html): Cast to unsigned char * when calling
2826         htmlfindurl.
2827
2828         * html.c (htmlfindurl): Use unsigned char.
2829
2830         * version.c: Changed version to 1.4.3.
2831
2832 1996-11-25  Hrvoje Niksic  <hniksic@srce.hr>
2833
2834         * version.c: Released 1.4.2.
2835
2836         * ftp.c (getftp): Simplified assertion.
2837         (ftp_loop_internal): Remove symlink before downloading.
2838         (ftp_retrieve_list): Unlink the symlink name before attempting to
2839         create a symlink!
2840
2841         * options.h (struct options): Renamed print_server_response to
2842         server_response.
2843
2844         * ftp.c (rel_constr): Removed.
2845         (ftp_retrieve_list): Don't use it.
2846         (ftp_retrieve_list): Use opt.retr_symlinks.
2847
2848 1996-11-24  Hrvoje Niksic  <hniksic@srce.hr>
2849
2850         * main.c (main): New option retr_symlinks.
2851
2852         * url.c (convert_links): Print verbose message.
2853
2854 1996-11-24  Hrvoje Niksic  <hniksic@srce.hr>
2855
2856         * http.c (http_loop): Reset newloc in the beginning of function;
2857         would cause FMR in retrieve_url.
2858
2859 1996-11-23  Hrvoje Niksic  <hniksic@srce.hr>
2860
2861         * recur.c (convert_all_links): Find the URL of each HTML document,
2862         and feed it to get_urls_html; would bug out.
2863         (convert_all_links): Check for l2 instead of dl; removed dl.
2864
2865         * url.c (convert_links): Don't refer to freed newname.
2866
2867         * recur.c (recursive_retrieve): Add this_url to urls_downloaded.
2868
2869         * main.c (main): Print the OS_TYPE in the debug output, too.
2870
2871         * recur.c (recursive_retrieve): Check for opt.delete_after.
2872
2873         * main.c (main): New option delete-after.
2874
2875         * init.c (setval): Cleaned up.
2876
2877 1996-11-21  Hrvoje Niksic  <hniksic@srce.hr>
2878
2879         * Makefile.in (wget): Make `wget' the default target.
2880
2881         * ftp.c (ftp_loop_internal): Move noclobber checking out of the
2882         loop.
2883         (ftp_retrieve_list): Warn about non-matching sizes.
2884
2885         * http.c (http_loop): Made -nc non-dependent on opt.recursive.
2886
2887         * init.c (setnum): Renamed from setnuminf; New argument flags.
2888         (setval): Use it.
2889
2890         * main.c (main): Sorted the options.
2891         (main): New option --wait.
2892
2893 1996-11-21  Shawn McHorse  <riffraff@txdirect.net>
2894
2895         * html.c (htmlfindurl): Reset s->in_quote after getting out of
2896         quotes.
2897
2898 1996-11-20  Hrvoje Niksic  <hniksic@srce.hr>
2899
2900         * version.c: Changed version to 1.4.2.
2901
2902 1996-11-20  Hrvoje Niksic  <hniksic@srce.hr>
2903
2904         * version.c: Released 1.4.1.
2905
2906         * html.c (html_quote_string): New function.
2907         (ftp_index): Use it.
2908         (htmlfindurl): A more gentle ending debug message.
2909
2910         * ftp.c (ftp_loop): Check for opt.htmlify.
2911
2912         * init.c: New command htmlify.
2913
2914         * ftp.c (getftp): Nicer error messages, with `'-encapsulated
2915         strings.
2916         (ftp_loop): Print size of index.html.
2917
2918         * init.c (setval): Implement "styles".
2919
2920         * main.c (main): New option dotstyle.
2921
2922 1996-11-19  Hrvoje Niksic  <hniksic@srce.hr>
2923
2924         * ftp.c (getftp): Close the master socket in case of errors, after
2925         bindport().
2926
2927         * connect.c (bindport): Initialize msock to -1.
2928
2929         * ftp.c (getftp): Initialize dtsock to -1.
2930
2931         * connect.c (closeport): Don't close sock if sock == -1.
2932
2933 1996-11-18  Hrvoje Niksic  <hniksic@srce.hr>
2934
2935         * init.c (setnuminf): Nuked default value -- just leave unchanged.
2936         (setval): Don't send default values.
2937         (defaults): Use DEFAULT_TIMEOUT -- aaargh.
2938
2939         * options.h (struct options): Use long for dot_bytes.
2940
2941         * init.c (setquota): Renamed to setbytes.
2942         (setval): Use setbytes on DOTBYTES.
2943
2944 1996-11-17  Hrvoje Niksic  <hniksic@srce.hr>
2945
2946         * ftp.c (getftp): Initialize con->dltime.
2947
2948         * recur.c (recursive_retrieve): Use same_host instead of
2949         try_robots; simply load robots_txt whenever the host is changed.
2950         (recursive_retrieve): Free forbidden before calling parse_robots.
2951
2952 1996-11-16  Hrvoje Niksic  <hniksic@srce.hr>
2953
2954         * retr.c (show_progress): Use them.
2955
2956         * options.h (struct options): New options dot_bytes, dots_on_line
2957         and dot_spacing.
2958
2959 1996-11-16  Mark Boyns  <boyns@sdsu.edu>
2960
2961         * recur.c (recursive_retrieve): Retrieve directories regardless of
2962         acc/rej rules; check for empty u->file.
2963
2964 1996-11-14  Hrvoje Niksic  <hniksic@srce.hr>
2965
2966         * init.c (setval): Use it.
2967
2968         * utils.c (merge_vecs): New function.
2969
2970         * init.c (setval): Reset the list-type functions when encountering
2971         "".
2972
2973 1996-11-14  Shawn McHorse  <riffraff@txdirect.net>
2974
2975         * recur.c (recursive_retrieve): Use base_url instead of this_url
2976         for no_parent.
2977
2978 1996-11-14  Shawn McHorse  <riffraff@txdirect.net>
2979
2980         * html.c (htmlfindurl): Reset s->in_quote after exiting the quote.
2981
2982 1996-11-13  Hrvoje Niksic  <hniksic@srce.hr>
2983
2984         * utils.c (sepstring): Rewrote; don't use strtok.
2985
2986         * recur.c (recursive_retrieve): Enter assorted this_url to slist
2987         when running the first time.
2988         (retrieve_robots): Warn to ignore errors when robots are loaded.
2989
2990         * utils.c (load_file): Moved from url.c.
2991
2992         * http.c: Made static variables const too in h* functions.
2993
2994         * main.c (main): Renamed --continue-ftp to --continue.
2995
2996         * recur.c (recursive_retrieve): Use it.
2997
2998         * utils.c (frontcmp): New function.
2999
3000         * url.c (accdir): New function.
3001
3002         * html.c (htmlfindurl): Recognize <area href=...>.
3003
3004         * ftp.c (ftp_retrieve_dirs): Implemented opt.includes.
3005
3006         * init.c (setval): Free the existing opt.excludes and
3007         opt.includes, if available.
3008
3009         * main.c (main): New option -I.
3010
3011 1996-11-12  Hrvoje Niksic  <hniksic@srce.hr>
3012
3013         * ftp.c (ftp_retrieve_glob): Do not weed out directories.
3014
3015         * version.c: Changed version to 1.4.1.
3016
3017 1996-11-11  Hrvoje Niksic  <hniksic@srce.hr>
3018
3019         * version.c: Released 1.4.0.
3020
3021 1996-11-10  Hrvoje Niksic  <hniksic@srce.hr>
3022
3023         * main.c (main): Free com and val after parse_line.
3024         (printhelp): Reorder the listing.
3025
3026         * http.c: More robust header parsing.
3027
3028         * http.c: Allow any number of spaces, or no spaces, precede ':'.
3029         (hskip_lws): New function.
3030         (haccepts_bytes): New function.
3031         (gethttp): Use it.
3032
3033         * init.c (setval): Check header sanity.
3034         (setval): Allow resetting of headers.
3035
3036 1996-11-10  Hrvoje Niksic  <hniksic@srce.hr>
3037
3038         * http.c (http_loop): Don't use has_wildcards.
3039
3040         * http.c (gethttp): Free all_headers -- would leak.
3041
3042         * recur.c (recursive_retrieve): Initialize depth to 1 instead of
3043         0 -- this fixes a long-standing bug in -rl.
3044
3045 1996-11-09  Hrvoje Niksic  <hniksic@srce.hr>
3046
3047         * ftp.c: Use -1 as "impossible" value for con->fd.
3048
3049         * url.h (URL_SEPARATOR): Don't treat `*' and `+' as separators.
3050
3051         * init.c (parse_line): Use isalpha.
3052
3053         * ftp-unix.c: Use HAVE_UNISTD_H.
3054
3055         * mtch.c (has_wildcards): Don't match \.
3056
3057         * http.c (http_loop): Warn on HTTP wildcard usage.
3058
3059 1996-11-08  Hrvoje Niksic  <hniksic@srce.hr>
3060
3061         * url.c (url_filename): Do not create numbered suffixes if
3062         opt.noclobber -- would bug out on -nc.
3063
3064 1996-11-07  Hrvoje Niksic  <hniksic@srce.hr>
3065
3066         * recur.c (parse_robots): Don't chuck out the commands without
3067         arguments (`Disallow:<empty>' didn't work).
3068         (parse_robots): Compare versions lowercase.
3069         (parse_robots): Match on base_version, not version_string!
3070         (parse_robots): Handle comments properly.
3071         (parse_robots): Match versions in a sane way.
3072
3073         * init.c: Print nicer error messages.
3074
3075         * version.c: Changed version to 1.4.0.
3076
3077 1996-11-06  Hrvoje Niksic  <hniksic@srce.hr>
3078
3079         * version.c: Released 1.4.0-test2.
3080
3081         * init.c (run_wgetrc): Close fp.
3082
3083         * ftp.c (ftp_retrieve_dirs): Allocate the correct length for
3084         u->dir.
3085
3086 1996-11-06  Hrvoje Niksic  <hniksic@srce.hr>
3087
3088         * init.c (setquota): Allow inf as quota specification.
3089
3090 1996-11-05  Hrvoje Niksic  <hniksic@srce.hr>
3091
3092         * ftp.c (ftp_retrieve_dirs): Return QUOTEXC if quota exceeded.
3093         (ftp_retrieve_glob): Return QUOTEXC on quota exceeded.
3094
3095         * main.c (main): Check for quota by comparison with downloaded
3096         stuff, not from status.
3097
3098         * connect.c (select_fd): Should compile on HPUX without warnings now.
3099
3100         * ftp.c (ftp_get_listing): Check whether ftp_loop_internal
3101         returned RETROK.
3102
3103 1996-11-04  Hrvoje Niksic  <hniksic@srce.hr>
3104
3105         * ftp.c (ftp_retrieve_glob): Print the pattern nicely.
3106         (getftp): Return FTPRETRINT on control connection error.
3107
3108         * html.c (htmlfindurl): Recognize <embed src=...> and
3109         <bgsound src=...>.
3110         (ftp_index): Handle username and password correctly.
3111
3112         * main.c (main): Made `-np' a synonim for --no-parent.
3113
3114 1996-11-02  Hrvoje Niksic  <hniksic@srce.hr>
3115
3116         * ftp.c (ftp_loop): Check for opt.ftp_glob too before calling
3117         ftp_retrieve_glob.
3118
3119         * version.c: Changed version to 1.4.0-test2.
3120
3121 1996-11-02  Hrvoje Niksic  <hniksic@srce.hr>
3122
3123         * version.c: Released 1.4.0-test1.
3124
3125         * url.c (str_url): Don't use sprintf when creating %2F-prefixed
3126         directory.
3127         (convert_links): Removed definition of make_backup.
3128
3129         * http.h: Removed definition of MAX_ERROR_LENGTH.
3130
3131         * host.c (ftp_getaddress): Check for "(none)" domains.
3132
3133         * ftp.c (ftp_retrieve_dirs): Docfix.
3134
3135         * http.c (gethttp): Use ou->referer instead of u->referer.
3136
3137         * retr.c (retrieve_url): Reset u to avoid freeing pointers twice;
3138         this was known to cause coredumps on Linux.
3139
3140         * html.c (ftp_index): Cast the argument to local_time to time_t *.
3141
3142 1996-11-01  Hrvoje Niksic  <hniksic@srce.hr>
3143
3144         * connect.c (select_fd): Use exceptfds -- once and for all.
3145
3146         * retr.c (retrieve_from_file): Free filename after
3147         recursive_retrieve.
3148         (retrieve_from_file): Send RFIRST_TIME to recursive_retrieve on
3149         first-time retrieval.
3150         (retrieve_from_file): Return uerr_t; new argument, count.
3151         (retrieve_from_file): Break on QUOTEXC.
3152
3153         * init.c (setquota): Fixed a bug that caused rejection of
3154         non-postfixed values..
3155
3156 1996-10-30  Hrvoje Niksic  <hniksic@srce.hr>
3157
3158         * version.c: Changed name to wget.
3159
3160         * connect.c (iread): Smarter use of select.
3161         (select_fd): Set errno on timeout.  If not timeout, return 1
3162         instead of 0.
3163
3164 1996-10-29  Hrvoje Niksic  <hniksic@srce.hr>
3165
3166         * ftp.c (ftp_loop_internal): Don't use con->cmd before
3167         establishing it.
3168
3169 1996-10-26  Hrvoje Niksic  <hniksic@srce.hr>
3170
3171         * http.c (gethttp): Send correct referer when using proxy.
3172         (gethttp): Use struct urlinfo ou to access the relevant data; send
3173         correct authorization in all cases.
3174
3175         * host.c (same_host): Use skip_uname to skip username and
3176         password.
3177
3178         * url.c (skip_uname): New function.
3179         (parseurl): Use it.
3180
3181         * host.c (same_host): Do not assume HTTP -- same_host should now
3182         be totally foolproof.
3183
3184         * url.c (skip_proto): New function.
3185         (parse_uname): Use it.
3186
3187         * http.c (gethttp): Create local user and passwd from what is
3188         given.
3189
3190         * url.c (parseurl): Check for HTTP username and password too.
3191
3192 1996-10-25  Hrvoje Niksic  <hniksic@srce.hr>
3193
3194         * config.h.in: Removed #define gethostbyname R...
3195
3196 1996-10-22  Hrvoje Niksic  <hniksic@srce.hr>
3197
3198         * version.c: Changed version to 1.4.0-test1.
3199
3200 1996-10-21  Hrvoje Niksic  <hniksic@srce.hr>
3201
3202         * version.c: "Released" 1.4b29.
3203
3204         * recur.c (recursive_retrieve): Check for no_parent.
3205
3206         * init.c (setval): Option update.
3207
3208         * main.c (main): New option no-parent.
3209
3210         * options.h (struct options): New variable no_parent.
3211
3212         * recur.c (recursive_retrieve): Only files are checked for
3213         opt.accepts and opt.rejects.
3214         (recursive_retrieve): Check directories for opt.excludes.
3215         (recursive_retrieve): Make the dir absolute when checking
3216         opt.excludes.
3217
3218         * html.c (htmlfindurl): Recognize <applet code=...> and <script
3219         src=...>
3220
3221 1996-10-18  Hrvoje Niksic  <hniksic@srce.hr>
3222
3223         * ftp.c (getftp): Do not line-break assert entries at all.
3224         (ftp_retrieve_dirs): docfix.
3225
3226         * connect.c (select_fd): Use fd + 1 as nfds.
3227
3228         * version.c: Changed version to 1.4b29.
3229
3230 1996-10-18  Hrvoje Niksic  <hniksic@srce.hr>
3231
3232         * version.c: "Released" 1.4b28.
3233
3234         * ftp.c (ftp_loop_internal): Check whether f->size == len and
3235         don't continue the loop if it is.
3236         (ftp_get_listing): Remove list_filename on unsuccesful loop.
3237
3238 1996-10-17  Hrvoje Niksic  <hniksic@srce.hr>
3239
3240         * ftp.c (ftp_loop_internal): Use strcpy to initialize tmp.
3241         (getftp): Do not use multiline assert.
3242
3243         * http.c (hparsestatline): Use mjr and mnr instead of major and
3244         minor, which don't compile on Ultrix.
3245         (http_loop): Use strcpy() to initialize tmp.
3246
3247         * all: Geturl -> Fetch
3248
3249 1996-10-17  Hrvoje Niksic  <hniksic@srce.hr>
3250
3251         * recur.c (parse_robots): Fixed an off-by-one bug when looking for
3252         ':'.
3253
3254         * html.c (htmlfindurl): Fixed several possible off-by-one bugs by
3255         moving `bufsize &&' to the beginning of each check in for-loops.
3256
3257         * recur.c (parse_robots): Close fp on exit.
3258
3259         * url.c (mymkdir): Check for each directory before creating.
3260
3261 1996-10-16  Hrvoje Niksic  <hniksic@srce.hr>
3262
3263         * version.c: Changed version to 1.4b28.
3264
3265 1996-10-16  Hrvoje Niksic  <hniksic@srce.hr>
3266
3267         * version.c: "Released" 1.4b27.
3268
3269         * init.c (parse_line): Use isspace.
3270         (parse_line): Free *com on all errors.
3271
3272         * ftp.c (ftp_loop): Change FTPOK to RETROK before exiting.
3273         (delelement): Use next instead of f->next and prev instead of
3274         f->prev.
3275         (delelement): Free the members of the deleted element.
3276
3277         * http.c (http_loop): Do not return RETROK on code != 20x.
3278
3279         * init.c (cleanup): Free opt.user_header.
3280         (cleanup): Free opt.domains.
3281
3282         * url.c (freelists): Moved to cleanup().
3283
3284         * http.c (hparsestatline): Docfix.
3285
3286         * main.c (main): Return with error status on unsuccesful
3287         retrieval.
3288
3289         * init.c (setval): Do not remove listing when mirroring.
3290
3291         * url.c (url_filename): Use opt.fileprefix.
3292
3293         * ftp.c (ftp_get_listing): Use url_filename to get filename for
3294         .listing.
3295
3296         * main.c (main): New option: -rn.
3297
3298 1996-10-15  Hrvoje Niksic  <hniksic@srce.hr>
3299
3300         * Makefile.in (RM): Added RM = rm -f.
3301
3302         * host.c (clean_hosts): New function.
3303         (free_hlist): Just free the list, no reset.
3304
3305         * version.c: Changed version to 1.4b27.
3306
3307 1996-10-13  Hrvoje Niksic  <hniksic@srce.hr>
3308
3309         * version.c: "Released" 1.4b26.
3310
3311         * retr.c (retrieve_from_file): If call get_urls_html with
3312         opt.spider to make it silent in spider mode.
3313
3314         * url.c (str_url): Use CLEANDUP instead of URL_CLEANSE.
3315
3316         * url.h (CLEANDUP): New macro.
3317
3318         * http.c (gethttp): Fixed a bug that freed location only when it
3319         was NULL.
3320
3321         * retr.c (retrieve_url): Free url if it will not be stored,
3322         i.e. newloc is NULL.
3323
3324         * html.c (htmlfindurl): Handle exiting from quotes correctly; the
3325         old version would bug out on <a href="x#a"href="y">.
3326
3327         * html.h (state_t): New member in_quote.
3328
3329         * html.c (htmlfindurl): Free s->attr at the beginning of
3330         attr-loop.
3331
3332         * recur.c (recursive_retrieve): Recognize RCLEANUP.
3333         (tried_robots): Make hosts a global variable.
3334         (recursive_retrieve): Free constr after URL host optimization.
3335         (tried_robots): Free urlinfo before exiting.
3336
3337         * utils.c (free_slist): New function.
3338
3339         * recur.c (recursive_retrieve): Use flags to add cleanup
3340         possibility.
3341
3342         * main.c (main): Free filename after recursive_retrieve.
3343
3344         * http.c (gethttp): Store successful responses too.
3345
3346 1996-10-12  Hrvoje Niksic  <hniksic@srce.hr>
3347
3348         * all: Constified the whole source.  This required some minor
3349         changes in many functions in url.c, possibly introducing bugs -- I
3350         hope not.
3351
3352         * ftp-basic.c: Removed last_respline.
3353
3354         * http.c (gethttp): Free type.
3355
3356         * host.c (same_host): Free real1 and real2.
3357
3358         * main.c (main): New option --spider.
3359
3360         * retr.c (get_contents): Don't reset errno.
3361
3362         * main.c (main): Sorted the options.
3363
3364         * connect.c (iread): Set errno to ETIMEDOUT only if it was left
3365         uninitialized by select().
3366
3367         * http.c (http_loop): Print the time when the connection is
3368         closed.
3369         (gethttp): Debug-print the HTTP request.
3370
3371 1996-10-11  Hrvoje Niksic  <hniksic@srce.hr>
3372
3373         * connect.c (iread): Do not try reading after timeout.
3374
3375         * main.c (main): Would bug out on -T.
3376
3377         * connect.c (select_fd): Do not use exceptfds.
3378         (iread): Set ETIMEDOUT on select_fd <= 0.
3379
3380         * version.c: Changed version to 1.4b26.
3381
3382 1996-10-10  Hrvoje Niksic  <hniksic@srce.hr>
3383
3384         * version.c: "Released" 1.4b25.
3385
3386         * ftp-unix.c (ftp_parse_unix_ls): Ignore lines without file name
3387         or link name.
3388
3389         * http.c (gethttp): Add errcode to struct hstat.
3390         (http_loop): Use it.
3391
3392         * url.c (no_proxy_match): Simplify using char** for no_proxy.
3393
3394         * options.h (struct options): Make opt.no_proxy a vector.
3395
3396         * utils.c (sepstring): Use !*s instead of !strlen(s).
3397
3398         * init.c (setval): Set opt.maxreclevel to 0 on --mirror.
3399         (getperms): Use ISODIGIT instead of isdigit.
3400
3401         * ftp.c (getftp): Print time.
3402
3403         * main.c (main): Use legible output of downloaded quantity.
3404
3405         * ftp.c (getftp): Use elapsed_time().
3406         (ftp_loop_internal): Use rate().
3407
3408         * http.c (http_loop): Add download ratio output; Use rate().
3409
3410         * utils.c (rate): New function.
3411
3412 1996-10-09  Hrvoje Niksic  <hniksic@srce.hr>
3413
3414         * http.c (http_loop): Use timer.
3415
3416         * ftp.c: Split to ftp-basic.c and ftp.c
3417
3418         * utils.c (reset_timer): New function.
3419         (elapsed_time): New function.
3420
3421         * retr.c (show_progress): Make bytes_in_line and offs long; should
3422         work on 16-bit machines.
3423
3424 1996-10-08  Hrvoje Niksic  <hniksic@srce.hr>
3425
3426         * url.c (in_acclist): New argument backward.
3427
3428         * ftp.c (ftp_retrieve_glob): Use acceptable() to determine whether
3429         a file should be retrieved according to suffix.
3430         (ftp_get_listing): Check the return value of unlink; Do not call
3431         ftp_retrieve_dirs if depth reached maxreclevel.
3432         (ftp_retrieve_dirs): Check whether the directory is in
3433         exclude-list.
3434
3435         * main.c (main): Print the version number at the beginning of
3436         DEBUG output.
3437         (main): Use strrchr when creating exec_name.
3438
3439         * ftp.c (ftp_retrieve_glob): Do not close control connection.
3440
3441         * version.c: Changed version to 1.4b25.
3442
3443 1996-10-07  Hrvoje Niksic  <hniksic@srce.hr>
3444
3445         * version.c: "Released" 1.4b24.
3446
3447         * Makefile.in: Rewrite.
3448
3449         * ftp.c (ftp_loop_internal): Likewise.
3450
3451         * retr.c (time_str): Check for failed time().
3452
3453         * html.c (htmlfindurl): Recognize <fig src> and <overlay src> from
3454         HTML3.0.
3455
3456         * retr.c (time_str): Return time_t *.
3457
3458         * connect.c (bindport): Close msock on unsuccesful bind.
3459         (bindport): The same for getsockname and listen.
3460
3461         * retr.c (retrieve_url): Allow any number of retries on
3462         proxy.
3463
3464         * http.c (gethttp): Do not treat errno == 0 as timeout.
3465         (http_loop): Likewise.
3466         (http_loop): Cosmetic changes.
3467
3468         * connect.c (iread): Set errno to ETIMEDOUT in case of timeout.
3469
3470         * retr.c (get_contents): Reset errno.
3471
3472         * ftp.c (getftp): Minor fixes.
3473
3474 1996-10-06  Hrvoje Niksic  <hniksic@srce.hr>
3475
3476         * http.c: Do not use backups.
3477
3478         * geturl.1 (WARNING): Warn that man-page could be obsolete.
3479
3480         * getopt.c (getopt_long): Moved to getopt.c
3481
3482         * geturl.texi: Enhanced.
3483
3484         * main.c (main): Use it.
3485
3486         * recur.c (convert_all_links): New function.
3487
3488         * utils.c (add_slist): New argument flags.
3489
3490         * recur.c (recursive_retrieve): Update a list of downloaded URLs.
3491         (parse_robots): Do not chuck out empty value fields.
3492         (parse_robots): Make yourself welcome on empty Disallow.
3493
3494         * version.c: Changed version to 1.4b24.
3495
3496 1996-10-06  Hrvoje Niksic  <hniksic@srce.hr>
3497
3498         * version.c: "Released" 1.4b23.
3499
3500         * ftp.c (ftp_loop_internal): Get the time after getftp.
3501
3502         * Makefile.in (install.info): New target.
3503         (install): Use it.
3504
3505         * http.c (http_loop): Fix output when doing -O.
3506
3507 1996-10-05  Hrvoje Niksic  <hniksic@srce.hr>
3508
3509         * geturl.texi: New file.
3510
3511         * main.c (main): Do not print the warnings and download summary if
3512         opt.quiet is set.
3513
3514         * version.c: Changed version to 1.4b23.
3515
3516 1996-10-05  Hrvoje Niksic  <hniksic@srce.hr>
3517
3518         * "Released" 1.4b22.
3519
3520         * atotm.c (atotm): Use True and False instead of TRUE and FALSE,
3521         to avoid redefinition warnings.
3522
3523         * host.c (store_hostaddress): Use memcpy() to copy the address
3524         returned by inet_addr.
3525
3526         * version.c: Changed version to 1.4b22.
3527
3528 1996-10-04  Hrvoje Niksic  <hniksic@srce.hr>
3529
3530         * version.c: "Released" 1.4b21.
3531
3532         * ftp-unix.c (ftp_parse_ls): Renamed to ftp_parse_unix_ls.
3533
3534         * ftp.c (ftp_port): Use conaddr.
3535         (getftp): Print the file length.
3536         (ftp_retrieve_list): Check the stamps of plain files only.
3537
3538         * connect.c (closeport): Do not call shutdown().
3539         (conaddr): New function.
3540
3541         * html.c (ftp_index): Made it dfp-aware.
3542
3543         * init.c (cleanup): New name of freemem. Close opt.dfp.
3544
3545         * ftp.c (getftp): Use opt.dfp if it is set.
3546
3547         * ftp-unix.c (ftp_parse_ls): Recognize time in h:mm format.
3548
3549         * ftp.c (ftp_retrieve_dirs): Fixed a bug that caused incorrect
3550         CWDs to be sent with recursive FTP retrievals.
3551
3552 1996-10-03  Hrvoje Niksic  <hniksic@srce.hr>
3553
3554         * recur.c (parse_robots): Made it more compliant with "official"
3555         specifications.
3556
3557         * http.c: New function.
3558
3559         * ftp-unix.c (ftp_parse_ls): Added better debug output.
3560
3561         * ftp.c (getftp): Print out the LIST in case of
3562         opt.print_server_response.
3563
3564         * version.c: Changed version to 1.4b21.
3565
3566 1996-10-01  Hrvoje Niksic  <hniksic@srce.hr>
3567
3568         * version.c: "Released" 1.4b20.
3569
3570         * README: Update.
3571
3572         * http.c (gethttp): Preset lengths of various headers instead of
3573         calculating them dynamically.
3574         (gethttp): Check for 206 partial contents.
3575
3576 1996-09-30  Hrvoje Niksic  <hniksic@srce.hr>
3577
3578         * configure.in: Set SYSTEM_GETURLRC to $libdir/geturlrc
3579
3580         * http.c (gethttp): Send the port number in the Host: header.
3581
3582 1996-09-29  Hrvoje Niksic  <hniksic@srce.hr>
3583
3584         * http.c (gethttp): Send host: header.
3585         (gethttp): Add the possibility of user-defined headers.
3586         (gethttp): Move decision about pragma: no-cache to http_loop,
3587         where it belongs.
3588         (gethttp): Pass a struct instead of enormous argument list.
3589         (http_loop): Use a new, fancier display format.
3590         (ftp_loop): Likewise.
3591
3592         * main.c: (hangup): Turn off buffering of the new log file.
3593
3594         * install-sh: Likewise.
3595
3596         * config.sub: Replace with the one in autoconf-2.10
3597
3598         * geturl.1: Update.
3599
3600         * init.c: New options httpuser and httppasswd.
3601
3602         * http.c: (base64_encode_line): New function.
3603         (gethttp): Send authentication.
3604
3605         * connect.c (make_connection): Use store_hostaddress.
3606
3607 1996-09-28  Hrvoje Niksic  <hniksic@srce.hr>
3608
3609         * host.c (store_hostaddress): New function.
3610
3611         * NEWS: Update.
3612
3613         * http.c (hgetrange): New function.
3614         (gethttp): Use ranges.
3615
3616         * utils.c (numdigit): Accept long instead of int.
3617
3618         * http.c (http_loop): Add restart capabilities.
3619
3620         * ftp.c (ftp_retrieve_glob): Fixed a bug that could cause matchres
3621         being used uninitialized.
3622         (ftp_retrieve_list): Similar fix.
3623
3624         * host.c (add_hlist): Fixed a bug that could cause cmp being used
3625         uninitialized.
3626
3627         * url.c (construct_relative): New function.
3628
3629         * recur.c (recursive_retrieve): Use it.
3630
3631         * retr.c (convert_links): New function.
3632
3633 1996-09-27  Hrvoje Niksic  <hniksic@srce.hr>
3634
3635         * url.c (free_urlpos): New function.
3636
3637         * recur.c (recursive_retrieve): Adapt.
3638
3639         * url.c (get_urls_html): Return a linked list instead of a vector.
3640
3641         * url.c (get_urls_file): Return a linked list instead of a vector.
3642
3643         * geturl.1: Update.
3644
3645         * http.c (gethttp): Implement it.
3646
3647         * init.c (setval): New option: SAVEHEADERS
3648
3649         * ftp.c (ftp_loop_internal): Do not set restval if listing is to
3650         be retrieved. Lack of this test caused bugs when the connection
3651         was lost during listing.
3652
3653         * retr.c (retrieve_url): Fixed a bug that caused
3654         coredumps. *newloc is now reset by default.
3655         (retrieve_url): Lift the twenty-tries limit on proxies.
3656
3657         * version.c: Changed version to 1.4b20.
3658
3659 1996-09-20  Hrvoje Niksic  <hniksic@srce.hr>
3660
3661         * version.c: "Released" 1.4b19.
3662
3663 1996-09-19  Hrvoje Niksic  <hniksic@srce.hr>
3664
3665         * ftp.c (ftp_loop_internal): Renamed from ftp_1fl_loop.
3666         (getftp): Changed prototype to accept ccon *.
3667
3668 1996-09-17  Hrvoje Niksic  <hniksic@srce.hr>
3669
3670         * ftp.c (ftp_retrieve_list): Fixed a bug that caused setting
3671         incorrect values to files pointed to by symbolic links.
3672         (ftp_1fl_loop): Do not count listings among the downloaded URL-s.
3673
3674 1996-09-16  Hrvoje Niksic  <hniksic@srce.hr>
3675
3676         * url.c (mkstruct): Do not prepend "./" in front of a pathname.
3677
3678         * main.c (main): New option: --user-agent.
3679
3680         * geturl.1: Ditto.
3681
3682         * init.h: Ditto.
3683
3684         * init.c (setval): Ditto.
3685
3686         * main.c (main): Rename "server-headers" to "server-response".
3687
3688         * ftp-unix.c (ftp_parse_ls): Check for asterisks at the end of
3689         executables in 'ls -F' listings.
3690
3691 1996-09-15  Hrvoje Niksic  <hniksic@srce.hr>
3692
3693         * url.c (parseurl): Remove realloc() and sprintf().
3694         (str_url): Get rid of sprintf().
3695
3696         * recur.c (recursive_retrieve): Enable FTP recursion through proxy
3697         servers.
3698
3699         * url.h (URL_CLEANSE): Made it else-resistant.
3700         (USE_PROXY): New macro.
3701
3702 1996-09-14  Hrvoje Niksic  <hniksic@srce.hr>
3703
3704         * NEWS: Update.
3705
3706         * version.c: Changed version to 1.4b19.
3707
3708 1996-09-14  Hrvoje Niksic  <hniksic@srce.hr>
3709
3710         * version.c: "Released" 1.4b18.
3711
3712         * url.c: Made it reallocate space exponentially.
3713
3714 1996-09-14  Drazen Kacar  <dave@fly.cc.fer.hr>
3715
3716         * html.c (htmlfindurl): Added <frame src> and <iframe src> among
3717         the list of stuff to fetch.
3718
3719 1996-09-13  Hrvoje Niksic  <hniksic@srce.hr>
3720
3721         * url.c (get_urls_html): Fixed a bug that caused SIGSEGV's with
3722         -Fi.
3723
3724         * html.c (htmlfindurl): Rewrite.
3725
3726         * http.c (gethttp): Use opt.proxy_cache.
3727
3728         * main.c (main): Added --cache option.
3729
3730         * ftp.c (ftp_response): Print server response if opt.print_server
3731         response is set.
3732         (getftp): Print newlines after each request if the server response
3733         is to be printed.
3734         (ftp_response): Copy the last response line to last_respline.
3735
3736         * http.c (gethttp): Add Pragma: nocache for retried
3737         proxy-retrievals.
3738
3739         * ftp.c (getftp): Use it.
3740
3741         * retr.c (buf_discard): New function.
3742
3743         * ftp.c (ftp_response): Use buf_readchar().
3744         (getftp): Flush the control connection buffer before calling
3745         get_contents().
3746
3747         * retr.c (buf_readchar): New function.
3748         (buf_flush): New function.
3749         (get_contents): Use buf_readchar() instead of read(x, x, 1).
3750         (get_contents): Use buf_flush.
3751
3752 1996-09-12  Hrvoje Niksic  <hniksic@srce.hr>
3753
3754         * ftp.c: Incorporate changes to ftp_response.
3755
3756         * ftp.c (ftp_response): Allocate the server response dynamically,
3757         as in read_whole_line and fetch_next_header.
3758
3759         * utils.c (read_whole_line): Fixed a bug that prevented reading
3760         the last line if it is not \n-terminated. Also fixed a possible
3761         memory overflow.
3762
3763         * http.c (fetch_next_header): Return malloc-ed string as large as
3764         needed.
3765         (gethttp): Use new fetch_next_header.
3766
3767 1996-09-12  Hrvoje Niksic  <hniksic@srce.hr>
3768
3769         * http.c (hgetlen): Compute the header length the first time only.
3770         (hgettype): Ditto.
3771         (hgetlocation): Ditto.
3772         (hgetmodified): Ditto.
3773
3774 1996-09-11  Hrvoje Niksic  <hniksic@srce.hr>
3775
3776         * sample.geturlrc: Update.
3777
3778 1996-09-10  Hrvoje Niksic  <hniksic@srce.hr>
3779
3780         * http.c (http_loop): Ditto.
3781
3782         * ftp.c (getftp): Open the output file as binary.
3783
3784         * version.c: Changed version to 1.4b18.
3785
3786 1996-09-10  Hrvoje Niksic  <hniksic@srce.hr>
3787
3788         * version.c: "Released" 1.4b17.
3789
3790         * ftp-unix.c (ftp_parse_ls): If unable to open file, return NULL
3791         instead of failed assertion.
3792
3793 1996-09-09  Hrvoje Niksic  <hniksic@srce.hr>
3794
3795         * ftp.c (ftp_get_listing): Add a numbered suffix to LIST_FILENAME
3796         if a file of that name already exists.
3797
3798 1996-09-05  Hrvoje Niksic  <hniksic@srce.hr>
3799
3800         * ftp.c (ftp_1fl_loop): Handler FTPPORTERR and FOPENERR correctly.
3801
3802         * config.h.in: Define gethostbyname as Rgethostbyname when using
3803         Socks.
3804
3805         * configure.in: Check for -lresolv if using Socks.
3806
3807         * version.c: Changed version to 1.4b17.
3808
3809 1996-07-15  Hrvoje Niksic  <hniksic@srce.hr>
3810
3811         * version.c: "Released" 1.4b16.
3812
3813         * http.c (gethttp): More intelligent check for first line of HTTP
3814         response.
3815         (gethttp): Would bug out on time-stamping.
3816
3817         * version.c: Changed version to 1.4b16.
3818
3819 1996-07-11  Hrvoje Niksic  <hniksic@srce.hr>
3820
3821         * version.c: Released 1.4b15.
3822
3823         * http.c (http_loop): Print \n after the loop entry, not before.
3824
3825         * url.c (url_filename): Use ISDOT.
3826
3827         * url.h (ISDOT): New macro.
3828
3829         * recur.c (recursive_retrieve): Change only opt.recursive for
3830         following FTP.
3831
3832 1996-07-11  Antonio Rosella <antonio.rosella@agip.it>
3833
3834         * socks/geturl.cgi: Fixed version No.
3835
3836         * socks/download-netscape.html: Ditto.
3837
3838         * socks/download.html: Changed socks.html to download.html.
3839
3840 1996-07-11  Hrvoje Niksic  <hniksic@srce.hr>
3841
3842         * url.c (url_filename): Check for opt.dirstruct instead for
3843         opt.recursive && opt.dirstruct.
3844
3845         * init.c (defaults): Ditto.
3846         (defaults): Reset dirstruct by default.
3847         (setval): Set opt.dirstruct whenever setting recursive.
3848
3849         * init.h: Removed FORCEDIRHIER.
3850
3851         * INSTALL: Added -L to socks-description.
3852
3853         * version.c: Changed version to 1.4b15.
3854
3855 1996-07-10  Hrvoje Niksic  <hniksic@srce.hr>
3856
3857         * version.c: "Released" 1.4b14.
3858
3859         * geturl.1: Update AUTHOR to include Rosella as contributor.
3860
3861         * NEWS: Update.
3862
3863         * socks/geturl.cgi: Simplified command creation, nuked <blink>.
3864
3865         * socks/geturl.cgi: Wrap nutscape extensions within if $netscape.
3866         (cal_time): Fix == to eq.
3867
3868         * socks/geturl.cgi: GPL-ized with permission of A. Rosella.
3869
3870         * geturl.1 (hostname): Moved URL CONVENTIONS to the beginning.
3871
3872         * Makefile.in: Use @VERSION@.
3873
3874         * configure.in: Check version from version.c.
3875
3876         * socks/geturl.cgi: Changed /pub/bin/perl to /usr/bin/perl.
3877
3878         * socks/download.html: Created from download-netscape.html, made
3879         HTML-2.0 compliant.
3880
3881         * recur.c (recursive_retrieve): Set opt.force_dir_hier when
3882         following FTP links from recursions.
3883
3884 1996-07-09  Hrvoje Niksic  <hniksic@srce.hr>
3885
3886         * url.c (mymkdir): Fixed a bug that prevented mymkdir() to create
3887         absolute directories correctly.
3888
3889         * version.c: Changed version to 1.4b14.
3890
3891 1996-07-09  Hrvoje Niksic  <hniksic@srce.hr>
3892
3893         * version.c: "Released" 1.4b13.
3894
3895         * url.c (make_backup): New function.
3896
3897         * http.c (http_loop): Make a backup copy of the local file (using
3898         rename(2)) before opening it.
3899
3900         * main.c (main): Added --backups.
3901
3902         * host.c (ftp_getaddress): Bail out on failed mycuserid().
3903         (ftp_getaddress): Check for leading dot on MY_DOMAIN.
3904         (ftp_getaddress): Check for empty, null or (null) domain.
3905
3906         * url.c (get_urls_html): If this_url is NULL, the base must have a
3907         protocol.
3908         (parseurl): Use has_proto.
3909
3910         * retr.c (retrieve_url): Warn when proxy is used with more than 20
3911         retries.
3912
3913         * url.c (mkstruct): Create the directory (calling mymkdir()) only
3914         if it is not already there.
3915         (has_proto): New function.
3916         (get_urls_html): Eliminate the remaining call to findurl -- use
3917         has_proto.
3918
3919         * geturl.1: Ditto.
3920
3921         * main.c: Change -X to -x.
3922
3923         * url.c (url_filename): Simplify creation of filename if
3924         prefix_files is set.
3925         (url_filename): Simplify everything. And I do mean *everything*.
3926         (mkstruct): Add dir_prefix before hostname.
3927         (path_simplify): Fixed a bug that caused writing outside the path
3928         string in case of "." and ".." path strings.
3929
3930 1996-07-06  Hrvoje Niksic  <hniksic@srce.hr>
3931
3932         * init.c: Added --mirror.
3933
3934         * main.c (main): Added -X to force saving of directory hierarchy.
3935
3936         * ftp.c (ftp_retrieve_list): Added recursion depth counter.
3937         (ftp_retrieve_list): Check whether quota is exceeded.
3938
3939         * url.c (get_urls_html): Skip leading blanks for absolute URIs.
3940
3941         * http.c (gethttp): Use referer if present.
3942
3943         * recur.c (recursive_retrieve): Set u->referer before calling
3944         retrieve_url.
3945
3946         * url.c (newurl): Use memset to nullify the struct members.
3947         (freeurl): Free the referer field too.
3948
3949         * url.h: Added referer to urlinfo.
3950
3951         * geturl.1: Updated the manual to document some of the new features.
3952
3953         * utils.c (numdigit): Moved from url.c.
3954
3955         * README: Rewritten.
3956
3957         * config.h.in: Add the support for socks.
3958
3959         * configure.in: Add the support for socks.
3960
3961         * url.c (url_filename): If the dir_prefix is ".", work with just
3962         the file name.
3963         (url_filename): Do not look for .n extensions if timestamping if
3964         turned on.
3965
3966         * retr.c (show_progress): Skip the over-abundant restval data, and
3967         print the rest of it with ',' instead of '.'.
3968
3969 1996-07-05  Hrvoje Niksic  <hniksic@srce.hr>
3970
3971         * retr.c (show_progress): Changed second arg. to long (as it
3972         should be).
3973         (show_progress): Moved to retr.c.
3974         (get_contents): Moved to retr.c.
3975
3976         * version.c: Change version to 1.4b13.
3977
3978 1996-07-05  Hrvoje Lacko <hlacko@fly.cc.fer.hr>
3979
3980         * url.c (in_acclist): Would return after the first suffix.
3981
3982 1996-07-04  Hrvoje Niksic  <hniksic@srce.hr>
3983
3984         * version.c: "Released" 1.4b12.
3985
3986         * url.c (path_simplify): More kludgifications.
3987         (get_urls_html): Use new parameters for htmlfindurl.
3988
3989         * html.c: Removed memorizing "parser states", since the new
3990         organization does not require them.
3991
3992         * init.c (run_geturlrc): Use read_whole_line.
3993
3994         * ftp-unix.c (ftp_parse_ls): Use read_whole_line.
3995
3996         * recur.c (parse_robots): Use read_whole_line.
3997
3998         * utils.c (read_whole_line): New function.
3999
4000         * recur.c (tried_robots): Use add_slist/in_slist, *much* cleaner.
4001
4002         * host.c (ngethostbyname): Call inet_addr just once. Yet to be
4003         tested on OSF and Ultrix.
4004         (add_hlist): New function.
4005         (free_hlist): New function.
4006         (search_host): New function.
4007         (search_address): New function.
4008         (realhost): Use search_host, search_address and add_hlist.
4009         (same_host): Replaced realloc() with strdupdelim(), made
4010         case-insensitive, fixed a memory leak.
4011
4012         * html.c (ftp_index): Fixed tm_min and tm_sec to be tm_hour and
4013         tm_min, like intended.
4014
4015         * version.c: Change user agent information to
4016         Geturl/version.
4017
4018 1996-07-03  Hrvoje Niksic  <hniksic@srce.hr>
4019
4020         * utils.c: Renamed nmalloc.c to utils.c, .h likewise.
4021
4022         * url.c (acceptable): Always accept directories.
4023
4024         * ftp-unix.c (ftp_parse_ls): Support brain-damaged "ls -F"-loving
4025         servers by stripping trailing @ from symlinks and trailing / from
4026         directories.
4027
4028         * ftp.c (ftp_loop): Debugged the "enhanced" heuristics. :-)
4029
4030         * url.c (skip_url): Use toupper instead of UCASE.
4031
4032         * host.c (sufmatch): Made it case-insensitive.
4033
4034         * url.c (match_backwards_or_pattern): Fixed i == -1 to j == -1.
4035         (match_backwards): New function, instead of
4036         match_backwards_or_pattern.
4037
4038         * recur.c (recursive_retrieve): Increased performance by
4039         introducing inl, which reduces number of calls to in_slist to only
4040         one.
4041
4042         * ftp.c (ftp_loop): Enhanced the heuristics that decides which
4043         routine to use.
4044
4045         * main.c (printhelp): Removed the warranty stuff.
4046
4047 1996-07-02  Hrvoje Niksic  <hniksic@srce.hr>
4048
4049         * url.c (add_slist): Simplify.
4050         (match_backwards_or_pattern): New function.
4051         (in_acclist): Use match_backwards_or_pattern.
4052         (matches): Remove.
4053
4054 1996-06-30  Hrvoje Niksic  <hniksic@srce.hr>
4055
4056         * ftp.c (ftp_loop): Call ftp_index on empty file names, if not
4057         recursive.
4058
4059         * html.c (ftp_index): Fixed to work. Beautified the output.
4060
4061         * ftp.c (ftp_retrieve_glob): Another argument to control whether
4062         globbing is to be used.
4063         (ftp_retrieve_list): Compare the time-stamps of local and remote
4064         files to determine whether to download.
4065
4066 1996-06-29  Hrvoje Niksic  <hniksic@srce.hr>
4067
4068         * ftp.c (rel_constr): New function.
4069
4070         * retr.c (retrieve_from_file): Check for text/html before
4071         retrieving recursively.
4072
4073         * main.c (main): Check whether the file is HTML before going into
4074         recursive HTML retrieving.
4075
4076         * ftp.c (ftp_retrieve_list): Manage directories.
4077         (ftp_retrieve_glob): Pass all the file-types to ftp_retrieve_list.
4078         (ftp_1fl_loop): Fixed a bug that caused con->com to be incorrectly
4079         initialized, causing bugchecks in getftp to fail.
4080
4081         * configure.in: Check for symlink.
4082
4083         * ftp.c (ftp_retrieve_list): Added support for symlinks.
4084
4085         * version.c: "Released" 1.4b10.
4086
4087         * atotm.c (atotm): Redeclared as time_t.
4088
4089         * init.c: New variable "timestamping".
4090
4091         * main.c (main): New option 'N'.
4092
4093         * http.c (hgetlocation): Case-insensitive match.
4094         (hgetmodified): New function.
4095         (http_loop): Implement time-stamping.
4096
4097 1996-06-28  Hrvoje Niksic  <hniksic@srce.hr>
4098
4099         * version.c: Changed version to 1.4b10
4100
4101         * atotm.c: New file, from phttpd.
4102
4103         * options.h (struct options): New parameter timestamping.
4104
4105         * version.c: 1.4b9 "released".
4106
4107         * recur.c (recursive_retrieve): Used linked list (ulist) for
4108         faster storing of URLs.
4109
4110         * url.c (get_urls_html): Removed the old kludge with comparing the
4111         outputs of htmlfindurl and findurl.
4112         (get_urls_html): Added better protocol support here.
4113         (create_hash): Removed, as well as add_hash and in_hash.
4114         (addslist): New function.
4115         (in_slist): ditto
4116
4117         * version.c: Released 1.4b8, changed version to b9.
4118
4119 1996-06-27  Hrvoje Niksic  <hniksic@srce.hr>
4120
4121         * ftp.c (freefileinfo): New function.
4122         (delelement): New function.
4123
4124         * everywhere: GPL!
4125
4126         * ftp.c (ftp_loop): Use ccon.
4127         (ftp_retrieve_glob): Likewise.
4128
4129         * ftp.h: Define ccon, to define status of control connection.
4130
4131         * ftp.c (ftp_get_listing): New function.
4132         (ftp_retrieve_more): New function.
4133         (ftp_retrieve_glob): New function.
4134
4135 1996-06-25  Hrvoje Niksic  <hniksic@srce.hr>
4136
4137         * configure.in: Removed the search for cuserid().
4138
4139         * init.c (getmode): Renamed to getperms.
4140
4141 1996-06-24  Hrvoje Niksic  <hniksic@srce.hr>
4142
4143         * version.c: New version.
4144
4145         * main.c (hangup): New function, that handles hangup. Hangup
4146         signal now causes geturl to stop writing on stdout, and to write
4147         to a log file.
4148
4149         * ftp.c (getftp): "Released" 1.4b7.
4150
4151         * html.c (htmlfindurl): Ignore everything inside <head>...</head>.
4152         (ftp_index): Use fileinfo/urlinfo.
4153
4154         * ftp-unix.c (ftp_parse_ls): New function.
4155         (symperms): New function.
4156
4157         * ftp.c (ftp_1fl_loop): New function, to handle 1-file loops.
4158
4159         * retr.c (retrieve_url): Added FTP support.
4160
4161 1996-06-23  Hrvoje Niksic  <hniksic@srce.hr>
4162
4163         * geturl.h: Removed NOTFTP2HTML enum.
4164         Added DO_LOGIN, DO_CWD and DO_LIST. LIST_ONLY is obsolete.
4165
4166         * ftp.c (getftp): Resynched with urlinfo.
4167         (getftp): Removed HMTL-ization of index.html from getftp.
4168
4169         * version.c: 1.4b6 "released".
4170
4171         * options.h (options): New struct, to keep options in.
4172
4173         * http.c (http_loop,gethttp): Synched with proxy.
4174
4175         * retr.c (retrieve_url): Implemented proxy retrieval.
4176
4177         * main.c (main): Use retrieve_from_file.
4178
4179 1996-06-22  Hrvoje Niksic  <hniksic@srce.hr>
4180
4181         * retr.c (retrieve_from_file): New function.
4182
4183         * url.c (parseurl): Modified to return URLOK if all OK. Protocol
4184         can be found in u->proto.
4185
4186         * ftp.c (ftp_response): Fixed to accept multi-line responses as
4187         per RFC 959.
4188
4189         * recr.c (recursive_retrieve): Take newloc from retrieve_url.
4190
4191         * url.c (mymkdir): Removed the file of the same name, if one
4192         exists.
4193         (isfile): New function.
4194         (mkstruct): Fixed the '/' glitches.
4195         (path_simplify): Hacked to treat something/.. correctly.
4196
4197 1996-06-21  Hrvoje Niksic  <hniksic@srce.hr>
4198
4199         * http.c (gethttp): Close the socket after error in headers.
4200         (http_loop): HEOF no longer a fatal header.
4201
4202         * loop.c (retrieve_url): When dt is NULL, do not modify it. This
4203         simplifies the syntax of calling retrieve_url.
4204
4205         * recr.c (recursive_retrieve): Modified to use get_urls_html.
4206
4207         * url.c (get_urls_file): New function.
4208         (get_urls_html): New function.
4209
4210         * recr.c (recursive_retrieve): Patched up to conform to the
4211         standards.
4212
4213         * http.c (gethttp): Synched with the rest...
4214         (gethttp): Treat only CONREFUSED specially, with connection
4215         errors.
4216
4217         * init.c,geturl.1,http.c (http_loop): Removed kill_error.
4218
4219 1996-06-20  Hrvoje Niksic  <hniksic@srce.hr>
4220
4221         * http.c (http_loop): New function.
4222
4223         * loop.c: Removed *lots* of stuff from retrieve_url.
4224
4225         * url.c (parseurl): Changed to work with urlinfo. Integrated
4226         username finding and path parsing.
4227         (newurl): New function.
4228         (freeurl): New function.
4229         (mkstruct): Removed the old bogosities, made it urlinfo-compliant.
4230         (url_filename): Likewise.
4231         (path_simplify): Accept relative paths too.
4232         (opt_url): Made urlinfo-compliant, removed bogosities.
4233         (path_simplify): Expanded to accept relative paths.
4234         (str_url): A replacement for hide_url
4235         (decode_string): Fixed a bug that caused malfunctioning when
4236         encountering an illegal %.. combination.
4237         (opt_url): Removed the argument. Dot-optimizations are now default.
4238
4239         * nmalloc.c (strdupdelim): New function.
4240
4241         * url.h: Added the urlinfo structure
4242
4243 1996-06-19  Hrvoje Niksic  <hniksic@srce.hr>
4244
4245         * url.c (hide_url): Thrown out the protocol assertion. Do not
4246         change the URL if the protocol if not recognized.
4247         (findurl): Put continue instead of break.
4248
4249 1996-06-18  Hrvoje Niksic  <hniksic@srce.hr>
4250
4251         * sample.geturlrc: Changed the defaults to be commented out and
4252         harmless (previous defaults caused pains if copied to
4253         ~/.geturlrc).
4254
4255         * http.c (gethttp): Print the HTTP request in debug mode.
4256
4257         * connect.c (iread): Added EINTR check loop to select-ing
4258         too. EINTR is now correctly handled with select().
4259
4260         * TODO: new file
4261
4262 1996-05-07  Hrvoje Niksic  <hniksic@srce.hr>
4263
4264         * host.c (same_host): Made the function a little bit more
4265         intelligent regarding diversified URL syntaxes.
4266
4267         * url.c (skip_url): Spaces are now skipped after URL:
4268
4269         * Released 1.3.1 with the patch to prevent crashing when sending
4270         NULL to robot* functions and the patch to compile "out of the box"
4271         on AIX.
4272
4273         * recr.c (recursive_retrieve): Added checking whether this_url is
4274         NULL when calling the robot functions.
4275
4276         * ChangeLog: New file.