[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kfm-devel
Subject:    Re: 1.1 kioslave (HTTP redirection) bug ?
From:       Waldo Bastian <bastian () ens ! ascom ! ch>
Date:       1999-02-15 9:26:24
[Download RAW message or body]

David Faure wrote:
> 
> Please have a look at bug #649 :
> what happens is a HTTP redirection in a loop.
> 
> Had a look at kioslave/http.cpp :
> 
>     else if ( strncasecmp( buffer, "Location: ", 10 ) == 0 )
>             {
>                 Close();
>                 KURL u( url );
>                 KURL u2( u, buffer + 10 );
>                 emit redirection( u2.url() );
> //              return Open( &u2, currentMode );
>                 bytesleft = 0;
>                 return (SUCCESS);
>             }
> 
>         }
>         emit mimeType( mType );
>         if (!Cookie.isEmpty())
>         {
>            emit cookie( url.data(), Cookie.data() );
>         }
> 
> The redirection is emitted before the cookie is, and I think that's the
> problem - shouldn't there be the cookie first, then the redirection ?
> Ok, I tested adding the "if (...) emit cookie" before the redirection, and
> added a debug(). There _is_ a cookie, as well as the redirection, but the
> hack doesn't change anything.

Yes, I think you are right here. Is there a defined order for headers
btw? Otherwise we would have to parse all headers first, and only THEN
start to do any actions.

Aren't these kioslaves going to be replaced btw?

Cheers,
Waldo
-- 
KDE, Making The Future of Computing Available Today       
http://www.kde.org

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic