diff --git a/prodScreen_buttonsTest.c b/prodScreen_buttonsTest.c index 2fe2a74..03ed7ef 100644 --- a/prodScreen_buttonsTest.c +++ b/prodScreen_buttonsTest.c @@ -22,7 +22,7 @@ int launch_prod_screen_buttons(int argc, char *argv[]){ SDL_Rect text_pos; SDL_Event event; int stop_menu_loop = 0; - int res = 2; // 2=FAIL + int res = EXIT_FAILURE; int render = 0; int time_left = time_left_FAIL; int prev_ms = 0; @@ -195,7 +195,7 @@ int launch_prod_screen_buttons(int argc, char *argv[]){ /* Print not touched buttons if time_left */ if(!time_left){ - res = 2; + res = ERROR_MANUAL_FAIL; printf(" Missing Keys: "); for (i = 0; i < NB_KEYS; i++){ diff --git a/prodScreen_displayTest.c b/prodScreen_displayTest.c index a13ef29..1c9282e 100644 --- a/prodScreen_displayTest.c +++ b/prodScreen_displayTest.c @@ -9,7 +9,7 @@ int launch_prod_screen_display(int argc, char *argv[]){ int stop_menu_loop = 0; int timeout = 31; int prev_ms = 0; - int res = ERROR_MANUAL_FAIL; + int res = EXIT_FAILURE; /* Main loop */ while (!stop_menu_loop && timeout) diff --git a/prodScreen_failScreen.c b/prodScreen_failScreen.c index 9793366..686bb4d 100644 --- a/prodScreen_failScreen.c +++ b/prodScreen_failScreen.c @@ -6,7 +6,7 @@ static int wait_event_loop(){ SDL_Event event; int stop_menu_loop = 0; - int res = 0; + int res = EXIT_FAILURE; /// -------- Main loop --------- while (!stop_menu_loop) diff --git a/prodScreen_ledTest.c b/prodScreen_ledTest.c index 13c663d..f8f0540 100644 --- a/prodScreen_ledTest.c +++ b/prodScreen_ledTest.c @@ -5,7 +5,7 @@ static int wait_event_loop(){ SDL_Event event; int stop_menu_loop = 0; - int res = 0; + int res = EXIT_FAILURE; /// -------- Main loop --------- while (!stop_menu_loop) diff --git a/prodScreen_magnetTest.c b/prodScreen_magnetTest.c index 5121239..43ee440 100644 --- a/prodScreen_magnetTest.c +++ b/prodScreen_magnetTest.c @@ -15,7 +15,7 @@ void handle_sigusr1(int sig) static int wait_event_loop(){ SDL_Event event; - int res = 0; + int res = EXIT_FAILURE; /// -------- Main loop --------- while (!stop_menu_loop) diff --git a/prodScreen_showImage.c b/prodScreen_showImage.c index 4e30577..3bbc7b1 100644 --- a/prodScreen_showImage.c +++ b/prodScreen_showImage.c @@ -57,7 +57,7 @@ int launch_prod_screen_showImage(int argc, char *argv[]){ SDL_Event event; SDL_Surface *text_surface = NULL; SDL_Rect text_pos; - int res = 0; + int res = EXIT_FAILURE; int stop_menu_loop = 0; /* Load Img */ diff --git a/prodScreen_speakerTest.c b/prodScreen_speakerTest.c index 81949dc..f3c7dc6 100644 --- a/prodScreen_speakerTest.c +++ b/prodScreen_speakerTest.c @@ -6,7 +6,7 @@ static int wait_event_loop(){ SDL_Event event; int stop_menu_loop = 0; - int res = 0; + int res = EXIT_FAILURE; /// -------- Main loop --------- while (!stop_menu_loop) diff --git a/prodScreen_validation.c b/prodScreen_validation.c index 459db61..8962719 100644 --- a/prodScreen_validation.c +++ b/prodScreen_validation.c @@ -6,7 +6,7 @@ static int wait_event_loop(){ SDL_Event event; int stop_menu_loop = 0; - int res = 0; + int res = EXIT_FAILURE; /// -------- Main loop --------- while (!stop_menu_loop) diff --git a/prodScreen_waitBattery.c b/prodScreen_waitBattery.c index 1bbc46e..168099b 100644 --- a/prodScreen_waitBattery.c +++ b/prodScreen_waitBattery.c @@ -10,7 +10,7 @@ static int is_battery_present(){ char buf[10]; FILE *fp; - int res = 0; + int res = EXIT_FAILURE; /* Read battery file */ if ((fp = fopen(BATTERY_PRESENT_FILE, "r")) == NULL) {