Skip to content

Commit

Permalink
Added error code exit
Browse files Browse the repository at this point in the history
  • Loading branch information
olteanu-ca committed Jul 18, 2013
1 parent 4161561 commit dcc8ff1
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,9 @@ void exit_handler(int s) {
system("clear"); // Tell the terminal to clear itself
#endif

if(g != NULL)
if(g->game_error())
exit(1);
exit(0);
}
}

0 comments on commit dcc8ff1

Please sign in to comment.