2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-31 22:46:10 +00:00

crash on close fixed

This commit is contained in:
John Preston
2015-12-28 20:23:27 +03:00
parent 9a3489694e
commit 43e173567f
3 changed files with 7 additions and 4 deletions

View File

@@ -489,7 +489,7 @@ int32 Application::updatingReady() {
#endif
FileUploader *Application::uploader() {
if (!::uploader) ::uploader = new FileUploader();
if (!::uploader && !App::quiting()) ::uploader = new FileUploader();
return ::uploader;
}
@@ -878,6 +878,7 @@ void Application::closeApplication() {
Application::~Application() {
App::setQuiting();
window->setParent(0);
anim::stopManager();
@@ -886,8 +887,10 @@ Application::~Application() {
closeApplication();
App::deinitMedia();
deinitImageLinkManager();
mainApp = 0;
delete ::uploader;
#ifndef TDESKTOP_DISABLE_AUTOUPDATE
delete updateReply;
updateReply = 0;