From a4c3bb6153b6fd1a8d54abde6f7d9ecd593a4e4d Mon Sep 17 00:00:00 2001 From: ultramage Date: Wed, 17 Oct 2007 17:20:01 +0000 Subject: Using predefined constants as parameters to the exit() function. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11501 54d463be-8e91-2dee-dedb-b68131a5f0ec --- src/map/npc.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/map/npc.c') diff --git a/src/map/npc.c b/src/map/npc.c index 177612b50..35515e33c 100644 --- a/src/map/npc.c +++ b/src/map/npc.c @@ -201,10 +201,10 @@ int npc_event_export(char* lname, void* data, va_list ap) ev = (struct event_data *) aMalloc(sizeof(struct event_data)); if (ev==NULL) { ShowFatalError("npc_event_export: out of memory !\n"); - exit(1); + exit(EXIT_FAILURE); }else if (p==NULL || (p-lname)>NAME_LENGTH) { ShowFatalError("npc_event_export: label name error !\n"); - exit(1); + exit(EXIT_FAILURE); }else{ ev->nd = nd; ev->pos = pos; @@ -371,7 +371,7 @@ int npc_timerevent_import(char* lname, void* data, va_list ap) else te= (struct npc_timerevent_list*)aRealloc( te, sizeof(struct npc_timerevent_list) * (i+1) ); if(te==NULL){ ShowFatalError("npc_timerevent_import: out of memory !\n"); - exit(1); + exit(EXIT_FAILURE); } for(j=0;jt){ @@ -1604,7 +1604,7 @@ int npc_convertlabel_db(DBKey key, void* data, va_list ap) // here we check if the label fit into the buffer if (len > 23) { ShowError("npc_parse_script: label name longer than 23 chars! '%s'\n (%s)", lname, current_file); - exit(1); + exit(EXIT_FAILURE); } safestrncpy(lst[num].name, lname, NAME_LENGTH); lst[num].pos = pos; @@ -1658,7 +1658,7 @@ static void npc_parse_script_line(char* p, int* curly_count, int line) } if(string_flag) { printf("Missing '\"' at file %s line %d\n", current_file, line); - exit(1); + exit(EXIT_FAILURE); } } -- cgit v1.2.3-60-g2f50