Debugger: Fix oversight in TeamDebugger.

- In the case where the target team terminates, the subsequent prompt
  to ask the user what action they wish to take in response needs to
  take into account the possibility that the UserInterface in question
  hasn't yet implemented such prompting. Treat such a case as equivalent
  to asking the debugger to quit.

Addresses part of #10292.
This commit is contained in:
Rene Gollent 2015-07-18 16:32:33 -04:00
parent e7b593f31c
commit a3b04ab398
1 changed files with 15 additions and 5 deletions

View File

@ -1657,11 +1657,21 @@ TeamDebugger::_HandleTeamDeleted(TeamDeletedEvent* event)
message, "Do nothing", "Quit", fCommandLineArgc != 0
? "Restart team" : NULL);
if (result == 1)
switch (result) {
case 1:
case -1:
{
PostMessage(B_QUIT_REQUESTED);
else if (result == 2) {
break;
}
case 2:
{
_SaveSettings();
fListener->TeamDebuggerRestartRequested(this);
break;
}
default:
break;
}
return true;