QNetworkReplyHandler is delicious spaghetti.
Created attachment 86271 [details] Proposed patch
Attachment 86271 [details] did not pass style-queue: Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'Source/WebCore/ChangeLog', u'Source/WebCor..." exit_code: 1 Source/WebCore/platform/network/qt/QNetworkReplyHandler.h:47: The parameter name "handle" adds no information, so it should be removed. [readability/parameter_name] [5] Total errors found: 1 in 4 files If any of these errors are false positives, please file a bug against check-webkit-style.
Comment on attachment 86271 [details] Proposed patch View in context: https://bugs.webkit.org/attachment.cgi?id=86271&action=review Generally looks good. All tests are passing I suppose :-) ? > Source/WebCore/platform/network/qt/QNetworkReplyHandler.cpp:182 > + , m_deferStart(true) Shouldn't it be defers? > Source/WebCore/platform/network/qt/QNetworkReplyHandler.cpp:184 > + , m_deferSendResponseIfNeeded(false) So what is ifNeeded? the defer or the send? tricky how to name these.
(In reply to comment #3) > (From update of attachment 86271 [details]) > View in context: https://bugs.webkit.org/attachment.cgi?id=86271&action=review > > Generally looks good. All tests are passing I suppose :-) ? > > > Source/WebCore/platform/network/qt/QNetworkReplyHandler.cpp:182 > > + , m_deferStart(true) > > Shouldn't it be defers? > > > Source/WebCore/platform/network/qt/QNetworkReplyHandler.cpp:184 > > + , m_deferSendResponseIfNeeded(false) > > So what is ifNeeded? the defer or the send? tricky how to name these. Btw, I dislike the names loadSynchro.. Also it is not really a kind/mode anymore and it is either sync or async.
DataType { AsynchronousData, SynchronousData } ? just thinking here.
Created attachment 86272 [details] Proposed patch v2 Updated patch with improved names. Also sprinkled some assertions over the code.
Comment on attachment 86272 [details] Proposed patch v2 That looks good to me. I you have the courage to continue cleaning, it would be nice to make redirection a bit easier to understand. :) Maybe the constructor should be just calling init() so that the same init() could be called from the redirection called. This recycling of the current QNetworkReplyHandler is confusing :(
Comment on attachment 86272 [details] Proposed patch v2 Clearing flags on attachment: 86272 Committed r81560: <http://trac.webkit.org/changeset/81560>
All reviewed patches have been landed. Closing bug.