mirror of
https://github.com/YACReader/yacreader
synced 2025-06-04 01:28:55 -04:00
fixed crash closing YACReaderLibrary after using the server (improved shutdown)
This commit is contained in:
parent
dee244455e
commit
2085e16900
@ -49,5 +49,11 @@ int main( int argc, char ** argv )
|
||||
/*mw->resize(800,480);
|
||||
mw->showMaximized();*/
|
||||
|
||||
return app.exec();
|
||||
int ret = app.exec();
|
||||
|
||||
//server shutdown
|
||||
s->stop();
|
||||
delete s;
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
@ -64,7 +64,7 @@ void Startup::start() {
|
||||
void Startup::stop() {
|
||||
qDebug("ServiceHelper: Service has been stopped");
|
||||
// QCoreApplication destroys all objects that have been created in start().
|
||||
listener->close();
|
||||
delete listener;
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user