ftp bug in 1.10

2005-06-15 Thread Herold Heiko
I have a reproducable report (thanks Igor Andreev) about a little verbouse
log problem with ftp with my windows binary, is this reproducable on other
platforms, too ?

wget -v ftp://garbo.uwasa.fi/pc/batchutil/buf01.zip
ftp://garbo.uwasa.fi/pc/batchutil/rbatch15.zip  

(seems to happen with any ftp download I tried though)

Last line of output is:

Downloaded:  bytes in 2 files

Note missing number of bytes.
Heiko

-- 
-- PREVINET S.p.A. www.previnet.it
-- Heiko Herold [EMAIL PROTECTED] [EMAIL PROTECTED]
-- +39-041-5907073 ph
-- +39-041-5907472 fax


Re: ftp bug in 1.10

2005-06-15 Thread Jochen Roderburg

Herold Heiko schrieb:

I have a reproducable report (thanks Igor Andreev) about a little verbouse
log problem with ftp with my windows binary, is this reproducable on other
platforms, too ?

wget -v ftp://garbo.uwasa.fi/pc/batchutil/buf01.zip
ftp://garbo.uwasa.fi/pc/batchutil/rbatch15.zip  

(seems to happen with any ftp download I tried though)

Last line of output is:

Downloaded:  bytes in 2 files

Note missing number of bytes.
Heiko



I see the same under Windows, but with a Linux version the output is 
correct. And it happens not only with ftp, also with multiple http requests.


Regards, J.Roderburg





Re: Small bug in Wget manual page

2005-06-15 Thread Hrvoje Niksic
Mauro Tortonesi [EMAIL PROTECTED] writes:

 this seems to be already fixed in the 1.10 documentation.

Now that 1.10 is released, we should probably update the on-site
documentation.


Re: Small bug in Wget manual page

2005-06-15 Thread Mauro Tortonesi
On Wednesday 15 June 2005 02:05 pm, Hrvoje Niksic wrote:
 Mauro Tortonesi [EMAIL PROTECTED] writes:
  this seems to be already fixed in the 1.10 documentation.

 Now that 1.10 is released, we should probably update the on-site
 documentation.

i am doing it right now.

-- 
Aequam memento rebus in arduis servare mentem...

Mauro Tortonesi  http://www.tortonesi.com

University of Ferrara - Dept. of Eng.http://www.ing.unife.it
Institute for Human  Machine Cognition  http://www.ihmc.us
GNU Wget - HTTP/FTP file retrieval tool  http://www.gnu.org/software/wget
Deep Space 6 - IPv6 for Linuxhttp://www.deepspace6.net
Ferrara Linux User Group http://www.ferrara.linux.it


Re: wget 1.10 problems under AIX

2005-06-15 Thread Hrvoje Niksic
Thanks for the detailed report!

Jens Schleusener [EMAIL PROTECTED] writes:

 1) Only using the configure-option --disable-nls and the C compiler
 gcc 4.0.0 the wget-binary builds successfully

I'd be interested in seeing the error log without --disable-nls and/or
with the system compiler.

 although gcc outputs
 some compiler warnings like

   convert.c: In function 'convert_all_links':
   convert.c:95: warning: incompatible implicit declaration of built-in
  function 'alloca'

The alloca-declaring magic in config-post.h (taken from the Autoconf
manual) apparently doesn't take into account that GCC wants alloca
declared too.

 But simply calling the new wget like

   wget http://www.example.com/

 I got always errors like

   --12:36:51--  http://www.example.com/
 = `index.html'
 Resolving www.example.com... failed: Invalid flags in hints.

This is really bad.  Apparently your version of getaddrinfo is broken
or Wget is using it incorrectly.  Can you intuit which flags cause the
problem?  Depending on the circumstances, Wget uses AI_ADDRCONFIG,
AI_PASSIVE, and/or AI_NUMERICHOST.

 After some testing I found that using the additional
 configure-option --disable-ipv6 solves that problem.

Because it disables IPv6 (and therefore the use of getaddrinfo)
altogether.

 2) Using the additional configure-option --with-ssl=/usr/local/contrib
 fails although the openssl (0.9.7g) header files are installed under
 /usr/local/contrib/include/openssl/ and the libssl.a under
 /usr/local/contrib/lib/.

This is not a standard layout, so the configure script is having
problems with it.  The supported layouts are one of:

* No flags are needed, the includes are found without -Iincludedir,
  and the library gets linked in without the need for -Llibdir.

* The library is installed in $root, which means that includes are in
  $root/include and the libraries in $root/lib.  OpenSSL's own default
  for $root is /usr/local/ssl, which Wget checks for.

To resolve situations like this, Wget should probably support
specifying additional include and library directories separately.
I believe you can work around this by specifying:

./configure CPPFLAGS=-I/usr/local/contrib/include -L/usr/local/contrib/lib

Can you check if that works for you?

 3) Using the native IBM C compiler (CC=cc) instead GNU gcc I got the
 compile error

   cc -qlanglvl=ansi -I. -I. -I/opt/include   -DHAVE_CONFIG_H
   -DSYSTEM_WGETRC=\/usr/local/contrib/etc/wgetrc\
   -DLOCALEDIR=\/usr/local/contrib/share/locale\ -O -c main.c
   main.c, line 147.16: 1506-275 (S) Unexpected text ',' encountered.

 Simply changing line 147 of src/main.c from

OPT__PARENT,

 to

OPT__PARENT

 let the compile error vanish (sorry, I am not a C expert).
[...]

It's a newer C feature that leaked into Wget -- sorry about that.

I'll try to get these fixed in Wget 1.10.1.


Re: wget 1.10 problems under AIX

2005-06-15 Thread Hrvoje Niksic
This patch should take care of the problems with compiling Wget 1.10
with the native IBM cc.

2005-06-15  Hrvoje Niksic  [EMAIL PROTECTED]

* host.h (ip_address): Remove the trailing comma from the type
enum in the no-IPv6 case.

* main.c (struct cmdline_option): Remove the trailing comma from
the enum.

Reported by Jens Schleusener.

Index: src/host.h
===
RCS file: /pack/anoncvs/wget/src/host.h,v
retrieving revision 1.27
diff -u -r1.27 host.h
--- src/host.h  2005/03/04 19:21:01 1.27
+++ src/host.h  2005/06/15 20:06:53
@@ -49,9 +49,9 @@
 typedef struct {
   /* Address type. */
   enum { 
-IPV4_ADDRESS, 
+IPV4_ADDRESS
 #ifdef ENABLE_IPV6
-IPV6_ADDRESS 
+, IPV6_ADDRESS 
 #endif /* ENABLE_IPV6 */
   } type;
 
Index: src/main.c
===
RCS file: /pack/anoncvs/wget/src/main.c,v
retrieving revision 1.137
diff -u -r1.137 main.c
--- src/main.c  2005/05/06 15:50:50 1.137
+++ src/main.c  2005/06/15 20:06:54
@@ -144,7 +144,7 @@
 OPT__DONT_REMOVE_LISTING,
 OPT__EXECUTE,
 OPT__NO,
-OPT__PARENT,
+OPT__PARENT
   } type;
   const void *data;/* for standard options */
   int argtype; /* for non-standard options */


Re: wget segfault on malformed working directory

2005-06-15 Thread Hrvoje Niksic
Nagy Ferenc Lszl [EMAIL PROTECTED] writes:

 If the ftp server returns invalid data (for example '221 Bye.') in
 response to PWD, wget segfaults because in ftp_pwd (ftp-basic.c)
 request will be NULL after the line 'request = strtok (NULL,
 \);', and this NULL will be passed to xstrdup.

Thanks for the report; this patch should fix the problem:

2005-06-15  Hrvoje Niksic  [EMAIL PROTECTED]

* ftp-basic.c (ftp_pwd): Handle malformed PWD response.

Index: src/ftp-basic.c
===
RCS file: /pack/anoncvs/wget/src/ftp-basic.c,v
retrieving revision 1.47
diff -u -r1.47 ftp-basic.c
--- src/ftp-basic.c 2005/05/16 22:08:57 1.47
+++ src/ftp-basic.c 2005/06/15 20:10:43
@@ -1081,6 +1081,7 @@
 return err;
   if (*respline == '5')
 {
+err:
   xfree (respline);
   return FTPSRVERR;
 }
@@ -1089,6 +1090,10 @@
  and everything following it. */
   strtok (respline, \);
   request = strtok (NULL, \);
+  if (!request)
+/* Treat the malformed response as an error, which the caller has
+   to handle gracefully anyway.  */
+goto err;
 
   /* Has the `pwd' been already allocated?  Free! */
   xfree_null (*pwd);


Re: [patch] some nongettextized messages

2005-06-15 Thread Hrvoje Niksic
Benno Schulenberg [EMAIL PROTECTED] writes:

 A few messages in wget-1.10-rc1 seem to have been overlooked during
 gettextization.  The patch repairs this.

Thanks a lot for catching these!  I'm about to apply them (with the
noted exception below) to the CVS.

 It's maybe a bit late to make such a change shortly before a 
 release, but I don't think the translators would mind making 
 another small update.

Unfortunately your patch was too late for the 1.10 release, but will
make it to 1.10.1 nonetheless.  :-)

 -  fprintf (stderr,
 -_(%s: %s: Invalid boolean `%s', use always, on, off, or 
 never.\n),
 +  fprintf (stderr, _(%s: %s: Invalid boolean `%s',
 + use `always', `on', `off', or `never'.\n),

Note that Wget 1.10 intentionally doesn't use C89 string
concatenation.  This particular change will be acceptable for 1.11,
though.


Re: [patch] some nongettextized messages

2005-06-15 Thread Benno Schulenberg
Hrvoje Niksic wrote:
 Unfortunately your patch was too late for the 1.10 release,

Yes, you were quicker than I thought.  I expected to have two weeks 
after an rc.  :)

  -  fprintf (stderr,
  -  _(%s: %s: Invalid boolean `%s', use always, on, off,
  or never.\n), +  fprintf (stderr, _(%s: %s: Invalid
  boolean `%s', + use `always', `on',
  `off', or `never'.\n),

 Note that Wget 1.10 intentionally doesn't use C89 string
 concatenation.  This particular change will be acceptable for
 1.11, though.

Ah, but the actual change is in the quoting, like it is used in the 
other Invalid boolean message, otherwise use always might be 
understood as always use.

Benno


Re: Small bug in Wget manual page

2005-06-15 Thread Mauro Tortonesi
On Wednesday 15 June 2005 02:16 pm, Mauro Tortonesi wrote:
 On Wednesday 15 June 2005 02:05 pm, Hrvoje Niksic wrote:
  Mauro Tortonesi [EMAIL PROTECTED] writes:
   this seems to be already fixed in the 1.10 documentation.
 
  Now that 1.10 is released, we should probably update the on-site
  documentation.

 i am doing it right now.

the web pages (including the documentation) on gnu.org have just been updated.

-- 
Aequam memento rebus in arduis servare mentem...

Mauro Tortonesi  http://www.tortonesi.com

University of Ferrara - Dept. of Eng.http://www.ing.unife.it
Institute for Human  Machine Cognition  http://www.ihmc.us
GNU Wget - HTTP/FTP file retrieval tool  http://www.gnu.org/software/wget
Deep Space 6 - IPv6 for Linuxhttp://www.deepspace6.net
Ferrara Linux User Group http://www.ferrara.linux.it


Re: Small bug in Wget manual page

2005-06-15 Thread Ulf Harnhammar
On Wed, Jun 15, 2005 at 03:53:40PM -0500, Mauro Tortonesi wrote:
 the web pages (including the documentation) on gnu.org have just been updated.

Nice! I have found some broken links and strange grammar, though:

* index.html: There are archives of the main GNU Wget list at
** fly.cc.fer.hr
** www.geocrawler.com
(neither works)

* wgetdev.html
** Translation Project page
(doesn't work)

* faq.html
** 3.1 [..]
Yes, starting from version 1.10, GNU Wget support files larger than 2GB.
(should be supports)

// Ulf



Re: Small bug in Wget manual page

2005-06-15 Thread Ulf Harnhammar
On Wed, Jun 15, 2005 at 11:57:42PM +0200, Ulf Harnhammar wrote:
 * faq.html
 ** 3.1 [..]
 Yes, starting from version 1.10, GNU Wget support files larger than 2GB.
 (should be supports)

** 2.0 How I compile GNU Wget?
(should be How do I)

// Ulf