mirror of
https://github.com/FunKey-Project/FunKey-ProdScreens.git
synced 2025-12-12 16:58:50 +01:00
EXIT_FAILURE by default
This commit is contained in:
parent
28f5ae37f7
commit
2ae61d2bac
@ -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++){
|
||||
|
||||
@ -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)
|
||||
|
||||
@ -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)
|
||||
|
||||
@ -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)
|
||||
|
||||
@ -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)
|
||||
|
||||
@ -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 */
|
||||
|
||||
@ -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)
|
||||
|
||||
@ -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)
|
||||
|
||||
@ -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) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user