Created attachment 57550 [details] possible fix Version: unspecified (using Devel) OS: Linux In KIO::AccessManager::createRequest: Since 3f3ed98 the new KIO::http_post API is used. For this to work, the request size is needed. Whenever I try to use a form (e.g. lwn.net login) this fails because sizeFromRequest(req) returns -1. I'm not certain what part is to blame for this. I'm using qtwebkit 2.1.0~2011week03-1 debian packages. I've attached a patch that creates a fall back to the old API if the size is not available. I'm not sure, if this the right fix, or if the bug is somewhere else. Reproducible: Always
That is curious. The only way sizeFromRequest returns a -1 is if "Content-Length" is missing. Hmm... curious why QtWebKit does not set that information by the time QNetworkAccessManager::createRequest is invoked! Anyhow, there is no need for this patch because the requirement that the size MUST always be specified before the http ioslave did any POST operation has already been relaxed due to the very same problem with the PUT operation. If you update to the latest version of kdelibs/kioslave/http/http.cpp (22ff0c7 and newer), then you should not encounter this problem. Otherwise, please re-open this ticket... Thanks for the report.