Skip to content

Commit db31a5c

Browse files
committed
BUG correction in wait battery: EXIT_FAILURE for the wrong res, causing test to suceed all the time
1 parent 2ae61d2 commit db31a5c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

prodScreen_waitBattery.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
static int is_battery_present(){
1111
char buf[10];
1212
FILE *fp;
13-
int res = EXIT_FAILURE;
13+
int res = 0;
1414

1515
/* Read battery file */
1616
if ((fp = fopen(BATTERY_PRESENT_FILE, "r")) == NULL) {
@@ -34,7 +34,7 @@ static int wait_event_loop(){
3434
SDL_Event event;
3535
int stop_menu_loop = 0;
3636
int prev_ms = 0;
37-
int res = ERROR_MANUAL_FAIL;
37+
int res = EXIT_FAILURE;
3838

3939
/// -------- Main loop ---------
4040
while (!stop_menu_loop)

0 commit comments

Comments
 (0)