home
·
contact
·
privacy
projects
/
plomrogue
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Move checking for error results into exit_err(), out of conditionals in the remaining...
[plomrogue]
/
src
/
rexit.c
diff --git
a/src/rexit.c
b/src/rexit.c
index f7bb3f23e8553132a8ad2a84c72be0448cb61b31..223c79ba0a2c84630bebe07739e8234a15d6ccbd 100644
(file)
--- a/
src/rexit.c
+++ b/
src/rexit.c
@@
-59,8
+59,12
@@
extern void exit_game(struct World * world)
-extern void exit_err(struct World * world, char * msg)
+extern void exit_err(
unsigned char fail,
struct World * world, char * msg)
{
+ if (0 == fail)
+ {
+ return;
+ }
cleanup(world);
printf(msg);
exit(EXIT_FAILURE);