Review Request 127077: kio_http: read and discard body after a 404 with errorPage=false.
David Faure
faure at kde.org
Sun Feb 14 22:18:15 UTC 2016
> On Feb. 14, 2016, 9:58 p.m., Milian Wolff wrote:
> > autotests/http_jobtest.cpp, line 71
> > <https://git.reviewboard.kde.org/r/127077/diff/2/?file=444332#file444332line71>
> >
> > what fails? can you `QEXPECT_FAIL` it? or did you fix it already (I assume that is the case)
LOL I forgot to remove that comment. This commit is the fix for it.
Thanks for the review, but I admit I would really like a kio_http contributor to look at it, I don't feel at ease with the change being correct in 100% of the cases.
Of course if we get any regressions, from now on we can actually add unittests....
- David
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/127077/#review92361
-----------------------------------------------------------
On Feb. 14, 2016, 9:57 p.m., David Faure wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/127077/
> -----------------------------------------------------------
>
> (Updated Feb. 14, 2016, 9:57 p.m.)
>
>
> Review request for KDE Frameworks, Dawit Alemayehu, Andreas Hartmetz, and Rolf Eike Beer.
>
>
> Repository: kio
>
>
> Description
> -------
>
> kio_http: read and discard body after a 404 with errorPage=false.
>
> When getting a 404 error with some content, the job succeeds and returns content
> (good for webbrowsers).
> The metadata "errorPage" can be set to false so that the job fails instead
> (useful for other cases, like favicon download, file copy etc.)
> However the rest of the headers, as well as the body must still be read and
> discarded, otherwise they clobber the next request (kio_http then starts
> parsing in the middle of some headers and says "DO NOT WANT").
>
> This is not a porting bug, I could reproduce it with kdelibs4 too.
>
>
> Diffs
> -----
>
> autotests/http_jobtest.cpp PRE-CREATION
> src/ioslaves/http/http.cpp e1013c8705e6588729d61ed45c43dc564415c41e
>
> Diff: https://git.reviewboard.kde.org/r/127077/diff/
>
>
> Testing
> -------
>
> Unittest.
>
> Please review this patch carefully, I don't have much experience with this code in kio_http, and the potential for regressions in cases that I didn't test is likely high.
>
>
> Thanks,
>
> David Faure
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20160214/49db970e/attachment.html>
More information about the Kde-frameworks-devel
mailing list