mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-06-07 23:53:58 +02:00
Fix crash in web request destructors.
This commit is contained in:
parent
50b78034a5
commit
233be5ec13
1 changed files with 6 additions and 1 deletions
|
@ -147,8 +147,13 @@ ServiceWebRequest &ServiceWebRequest::operator=(ServiceWebRequest &&other) {
|
||||||
|
|
||||||
void ServiceWebRequest::destroy() {
|
void ServiceWebRequest::destroy() {
|
||||||
if (const auto value = base::take(reply)) {
|
if (const auto value = base::take(reply)) {
|
||||||
value->deleteLater();
|
value->disconnect(
|
||||||
|
value,
|
||||||
|
&QNetworkReply::finished,
|
||||||
|
nullptr,
|
||||||
|
nullptr);
|
||||||
value->abort();
|
value->abort();
|
||||||
|
value->deleteLater();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue