On Mon, Jan 14, 2002 at 02:30:54PM +0100, Hrvoje Niksic wrote: > > moz wget-1.7 188 wget http://www.movementarian.org/oprofile-0.0.8.tar.gz > > --20:35:51-- http://www.movementarian.org/oprofile-0.0.8.tar.gz > > => `oprofile-0.0.8.tar.gz' > > Connecting to www.movementarian.org:80... connected! > > HTTP request sent, awaiting response... 302 Moved > > Location: http://www.movement.uklinux.net/oprofile-0.0.8.tar.gz [following] > > --20:35:52-- http://www.movement.uklinux.net/oprofile-0.0.8.tar.gz%20 > > => `oprofile-0.0.8.tar.gz ' > > If you examine this log carefully, you'll notice that their `Location' > header contains a trailing space. Wget even reencodes the space as > %20 to make the URL more readable, but it still retrieves the "wrong" > URL.
indeed. > Does someone else know if this is legal? I guess removing trailing > spaces from `Location' shouldn't be too harmful. Someone pointed out : http://www.ietf.org/rfc/rfc2616.txt 4.2 ... The field-content does not include any leading or trailing LWS: linear white space occurring before the first non-whitespace character of the field-value or after the last non-whitespace character of the field-value. Such leading or trailing LWS MAY be removed without changing the semantics of the field value. Any LWS that occurs between field-content MAY be replaced with a single SP before interpreting the field value or forwarding the message downstream. So wget should always remove it IMHO regards john -- "Now why did you have to go and mess up the child's head, so you can get another gold waterbed ? You fake-hair contact-wearing liposuction carnival exhibit, listen to my rhyme ..."
