Merge pull request #82 from AttorneyOnline/reload-fix
Ensure the advertiser actually exists before connecting the reload signal/slot
This commit is contained in:
commit
eded7932d0
@ -62,7 +62,10 @@ int main(int argc, char* argv[])
|
|||||||
}
|
}
|
||||||
|
|
||||||
server = new Server(settings.port, settings.ws_port);
|
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();
|
server->start();
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
Reference in New Issue
Block a user