Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 34129 - wget removes trailing slashes
Summary: wget removes trailing slashes
Status: RESOLVED WONTFIX
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High normal
Assignee: Seemant Kulleen (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-11-22 12:48 UTC by Todd Walton
Modified: 2005-05-11 15:52 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
'diff -pc' made against wget-1.8.2-r3/url.c (wget.url.c.patch,2.27 KB, patch)
2003-11-22 12:50 UTC, Todd Walton
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Todd Walton 2003-11-22 12:48:10 UTC
wget (1.9, 1.8.2, everything) removes one of two trailing slashes on the URL
given to it.  This is incompatible with Freenet (another package in Portage). 
If I say, for example,:

'wget http://localhost:8888/SSK@rjYFfgPHfolmcStiaoxESFfBXz8PAgM/FreenetHelp//'

wget will remove that last forward slash, making the URL incorrect, and giving
me an "ERROR 404: Not Found." error, so I can't use wget when I want to retrieve
a URL with two trailing slashes.  As I understand it, the wget people do this on
purpose, because it works around the two remaining (buggy) CERN web servers out
there, or some such.  Personally, however, I would like wget to fetch the URL I
give it.

I'm just hoping there's something you (Gentoo developer) can do.  Ask the wget
people, or make a compile-time patch maybe?  I will include a patch that works
against wget-1.8.2-r3.  I've looked in the wget-1.9 sources, and I can't find
where this patch would go in it.  The appropriate section of source must have
been drastically changed.

Reproducible: Always
Steps to Reproduce:
1. 'wget http://anyold.com/valid.url//'
2. Observe response.

Actual Results:  
ERROR 404: Not Found.

Expected Results:  
wget should have fetch me the page located at the URL I gave it.

Portage 2.0.49-r15 (default-x86-1.4, gcc-3.2.3, glibc-2.3.2-r3, 2.4.22-aa1)
=================================================================
System uname: 2.4.22-aa1 i686 AMD Athlon(tm) processor
Gentoo Base System version 1.4.3.10p1
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CFLAGS="-march=athlon -O2 -pipe -fomit-frame-pointer"
CHOST="i686-pc-linux-gnu"
COMPILER="gcc3"
CONFIG_PROTECT="/etc /var/qmail/control /usr/kde/2/share/config
/usr/kde/3/share/config /usr/X11R6/lib/X11/xkb /usr/kde/3.1/share/config
/usr/share/config"
CONFIG_PROTECT_MASK="/etc/gconf /etc/env.d"
CXXFLAGS="-march=athlon -O2 -pipe -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
FEATURES="sandbox ccache autoaddcvs"
GENTOO_MIRRORS="http://www.ibiblio.org/gentoo
ftp://ftp.ussg.iu.edu/pub/linux/gentoo ftp://ftp.gtlib.cc.gatech.edu/pub/gentoo
http://gentoo.seren.com/gentoo ftp://gentoo.noved.org/"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY=""
SYNC="rsync://rsync.namerica.gentoo.org/gentoo-portage"
USE="x86 oss apm avi crypt encode gif jpeg libwww motif mpeg ncurses pdflib png
quicktime spell truetype xml2 xmms xv zlib alsa gdbm slang readline arts aalib
svga ggi tcltk X sdl gpm tcpd pam ssl perl python esd imlib oggvorbis gtk qt kde
opengl mozilla cdr aavm dga j-nomsn java maildir mbox memlimit mmx moznoirc
moznomail mozsvg nptl pic static tiff type1 vim-with-x wmf xvid -cups
-foomaticdb -gnome -libg++ -mad -mikmod -nls -directfb -berkdb"
Comment 1 Todd Walton 2003-11-22 12:50:18 UTC
Created attachment 21095 [details, diff]
'diff -pc' made against wget-1.8.2-r3/url.c
Comment 2 SpanKY gentoo-dev 2003-11-22 14:54:27 UTC
the problem is a lot of webservers out on the internet will error if you have //
Comment 3 Maurice van der Pot (RETIRED) gentoo-dev 2004-12-11 17:11:06 UTC
What's the verdict? Will a change be made or will it stay the way it is?
Comment 4 Todd Walton 2004-12-11 17:18:24 UTC
I think, Maurice, that the answer to your question lies in the dates of the posts.  It's been over a year since I posted this, and nothing has happened.  Nothing likely will.  ={ 
Comment 5 Seemant Kulleen (RETIRED) gentoo-dev 2004-12-12 19:00:21 UTC
griffon, you can have wget if you want it -- my schedule is prohibitive until mid to late february and gregf is MIA and has been for a while.
Comment 6 Seemant Kulleen (RETIRED) gentoo-dev 2005-05-11 05:04:15 UTC
Todd, I'm sorry, but I can not justify the change to wget's behaviour -- I rather think you might take this issue upstream and talk with them about it.  Sorry for the latency in responses to this -- I feel bad to have left you hanging like that.
Comment 7 Todd Walton 2005-05-11 15:52:19 UTC
That's okay.  Thanks for closing out the bug.