ensure the advertiser actually exists before connecting the reload signal/slot
This commit is contained in:
parent
466089ad84
commit
522c9fb393
@ -62,7 +62,10 @@ int main(int argc, char* argv[])
|
||||
}
|
||||
|
||||
server = new Server(settings.port, settings.ws_port);
|
||||
QObject::connect(server, &Server::reloadRequest, advertiser, &Advertiser::reloadRequested);
|
||||
|
||||
if (advertiser != nullptr) {
|
||||
QObject::connect(server, &Server::reloadRequest, advertiser, &Advertiser::reloadRequested);
|
||||
}
|
||||
server->start();
|
||||
}
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user