Details
-
Bug
-
Resolution: Invalid
-
Not Evaluated
-
None
-
5.13.2
-
None
Description
QHash<QNetworkReply*, QString> crash when I use STL-style iterator to call reply->abort()
but if I call the reply->abort() by for loop, it's OK.
code by using iterator:
auto i = m_replyMap.begin(); while (i != m_replyMap.end()) { i.key()->abort(); i++; }
code by using for loop:
for (auto key : m_replyMap.keys()) { key->abort(); }
the debugger show that when access the nextNode, it just crash.
inline iterator operator++(int) { iterator r = *this; i = QHashData::nextNode(i); // stop in here return r; }