[patch] Making KDE work with (web based) proxy scripts again

Dawit A. adawit at kde.org
Wed Jan 14 03:02:35 GMT 2004

On Tuesday 13 January 2004 18:45, Scott Wheeler wrote:
> Hash: SHA1
> On Tuesday 13 January 2004 23:30, Dawit A. wrote:
> > Why ? The proxyscout code will always detect the URL is the same as the
> > one it is trying to download and return "DIRECT". See
> > kdelibs/kio/misc/kpac/proxyscout.cpp around line 66.
> [...]
> > Not yet. We all understand the problem, but we do not know the cause...
> > Can you please add debug statements to the below the line mentioned about
> > and  see if you ever get to it when the proxy attempts to download the
> > script file... BTW, I cannot duplicate this at all! It works fine for
> > me... There  must be something else going on here....
> Ok, I asked Waldo to look over this one earlier and got him to approve it
> so I already checked it in, (as I would rather have it working and a little
> unclear than not working and unclear for the release) but if we come up
> with a cleaner solution I'd be more than happy to revert that.

That is fine. I am more worried about discovering the actual cause of this 

> However, looking at the line you point out:
> if ( m_downloader && url == m_downloader->scriptURL() ) return "DIRECT";
> I'm pretty sure that I see the problem -- the equality operator here won't
> work in a lot of situations because the URL as one of the two (don't
> remember which off the top of my head -- I can only test this at work) is
> usually padded with a trailing "/" and the equality operator will return
> false.  i.e. in our case "http://proxy:8083" != "http://proxy:8083/"

I just do not see how this can be an issue in this case. :) There is no reason 
why the proxyURL should change from the original request to the point where 
it was attempting to download the proxy config file. But then again  I could 
always be wrong :)

> Tomorrow I'll try to switch the line above to use:
> url.equals( m_downloader->scriptURL(), true )

Can you please add a debug statement and see what the values of both of those 
URLs are ? Thanks...

Dawit A.
"Preach what you practice, practice what you preach"

More information about the kde-core-devel mailing list