X-Git-Url: https://jxself.org/git/?a=blobdiff_plain;f=cheat.c;h=d1e45e00a418675a1c50087c7b63d6de24c98a30;hb=58b44313d33a39285d394b7704d80823f4d15763;hp=4643462c1a659b0497ba34b024941660f6897481;hpb=bf2fa227f0786952ae4a632a1520bf1cf6663c98;p=open-adventure.git diff --git a/cheat.c b/cheat.c index 4643462..d1e45e0 100644 --- a/cheat.c +++ b/cheat.c @@ -1,4 +1,3 @@ -#define DEFINE_GLOBALS_FROM_INCLUDES #include #include #include @@ -10,9 +9,6 @@ struct game_t game; -long LNLENG, LNPOSN; -char rawbuf[LINESIZE], INLINE[LINESIZE + 1]; - FILE *logfp = NULL, *rfp = NULL; bool oldstyle = false; bool editline = true; @@ -54,7 +50,7 @@ int main(int argc, char *argv[]) " -v version number of save format.\n"); fprintf(stderr, " -o file name of save game to write.\n"); - exit(-1); + exit(EXIT_FAILURE); break; } } @@ -64,7 +60,7 @@ int main(int argc, char *argv[]) usage, argv[0]); fprintf(stderr, "ERROR: filename required\n"); - exit(-1); + exit(EXIT_FAILURE); } FILE *fp = NULL; @@ -92,7 +88,7 @@ int main(int argc, char *argv[]) if (fp == NULL) { fprintf(stderr, "Can't open file %s. Exiting.\n", savefilename); - exit(-1); + exit(EXIT_FAILURE); } savefile(fp, version);