wget bug

2001-10-08 Thread Dmitry . Karpov

Dear sir.

When I out to my browser (NN'3) line
http://find.infoart.ru/cgi-bin/yhs.pl?hidden=http%3A%2F%2F194.67.26.82word=FreeBSD
wget working correctly.

When I put this line to wget, wget change this line;
argument hidden is http:/194.67.26.82word,
argument word is empty. Where I am wrong?



wget segfault on ppc

2001-10-08 Thread David Roundy

Hello.  I have a patch to fix a problem with wget segfaulting on the
powerpc platform.  It happens in the logvprintf routine, due to differences
in the handling of va_lists on ppc vs. x86.  The problem was that it was
reusing a va_list after it had already been exhausted, and the following
fix should be portable on at least any platform using gcc.

I'm afraid the the patch may be malformed wrt whitespace, but it is small
enough that you shouldn't have a problem applying it by hand.

--- wget-1.7.old/src/log.c  Sun May 27 12:35:05 2001
+++ wget-1.7/src/log.c  Fri Sep 28 09:29:48 2001
@@ -280,9 +280,12 @@
 static void
 logvprintf (enum log_options o, const char *fmt, va_list args)
 {
+  va_list all_the_args;
+
   CHECK_VERBOSE (o);
   CANONICALIZE_LOGFP_OR_RETURN;

+  __va_copy(all_the_args,args);
   /* Originally, we first used vfprintf(), and then checked whether
  the message needs to be stored with vsprintf().  However, Watcom
  C didn't like ARGS being used twice, so now we first vsprintf()
@@ -310,7 +313,9 @@
  the systems where vsnprintf() is not available, we use
  the implementation from snprintf.c which does return the
  correct value.  */
- int numwritten =3D vsnprintf (write_ptr, available_size, fmt, args);
+  int numwritten;
+  __va_copy(args,all_the_args);
+ numwritten =3D vsnprintf (write_ptr, available_size, fmt, args);

  /* vsnprintf() will not step over the limit given by
  available_size.  If it fails, it will return either -1



-- 
David Roundy
http://civet.berkeley.edu/droundy/



msg01993/pgp0.pgp
Description: PGP signature


ampersand qoutied

2001-10-08 Thread Dmitry . Karpov

When I am running
wget 'http://www.pi2.ru:8101/cgi-bin/test-cgi?a=preb=post'
I have
QUERY_STRING = a=pre%26b=post
but when I put this URL to browser, I have
QUERY_STRING = a=preb=post

How can I download CGI-replyes via wget?

Please, reply directly.