summaryrefslogtreecommitdiffstats
path: root/src/network/access/qnetworkreplyimpl.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/network/access/qnetworkreplyimpl.cpp')
-rw-r--r--src/network/access/qnetworkreplyimpl.cpp10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/network/access/qnetworkreplyimpl.cpp b/src/network/access/qnetworkreplyimpl.cpp
index 1dad58c..83afddd 100644
--- a/src/network/access/qnetworkreplyimpl.cpp
+++ b/src/network/access/qnetworkreplyimpl.cpp
@@ -582,10 +582,6 @@ void QNetworkReplyImpl::abort()
return;
// stop both upload and download
- if (d->backend) {
- d->backend->deleteLater();
- d->backend = 0;
- }
if (d->outgoingData)
disconnect(d->outgoingData, 0, this, 0);
if (d->copyDevice)
@@ -599,6 +595,12 @@ void QNetworkReplyImpl::abort()
d->finished();
}
d->state = QNetworkReplyImplPrivate::Aborted;
+
+ // finished may access the backend
+ if (d->backend) {
+ d->backend->deleteLater();
+ d->backend = 0;
+ }
}
void QNetworkReplyImpl::close()