force quit the core on exit

This commit is contained in:
Nova 2025-06-29 18:53:29 +03:30
parent 467fcf5331
commit abd9ce37ef
2 changed files with 8 additions and 3 deletions

View File

@ -38,6 +38,14 @@ type server struct {
func (s *server) Exit(ctx context.Context, in *gen.EmptyReq) (out *gen.EmptyResp, _ error) {
out = &gen.EmptyResp{}
if needUnsetDNS {
needUnsetDNS = false
err := sys.SetSystemDNS("Empty", boxInstance.Network().InterfaceMonitor())
if err != nil {
log.Println("Failed to unset system DNS:", err)
}
}
// Connection closed
defer os.Exit(0)
return

View File

@ -787,9 +787,6 @@ void MainWindow::prepare_exit()
on_commitDataRequest();
//
NekoGui::dataStore->save_control_no_save = true; // don't change datastore after this line
neko_stop(false, true);
//
sem_stopped.acquire();
NekoGui_rpc::defaultClient->Exit();
mu_exit.unlock();
qDebug() << "prepare exit done!";