mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-03 10:22:45 -04:00
use a dialog when the port is unavailable
This commit is contained in:
parent
1711e96b18
commit
591fd7c648
@ -104,7 +104,14 @@ int main(int argc, char *argv[])
|
||||
// Create the server object.
|
||||
server = new WinStatsServer;
|
||||
if (!server->listen()) {
|
||||
nout << "Unable to open port.\n";
|
||||
ostringstream stream;
|
||||
stream
|
||||
<< "Unable to open port " << pstats_port
|
||||
<< ". Try specifying a different\n"
|
||||
<< "port number using pstats-port in your Config file.";
|
||||
string str = stream.str();
|
||||
MessageBox(toplevel_window, str.c_str(), "PStats error",
|
||||
MB_OK | MB_ICONEXCLAMATION);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user