Ignore:
Timestamp:
2018-01-04T20:47:53Z (6 years ago)
Author:
Jiří Zárevúcky <zarevucky.jiri@…>
Children:
facacc71
Parents:
cde999a
Message:

Wrap returns of errno from main() with EXIT_RC().

Returns of error code from main() prevent type checking when errno_t
and int are considered incompatible. In order to avoid the philosophical
discussion of what should and shouldn't be returned for main(), we simply
wrap the error values and leave the answer to the question for future
generations to decide.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/srv/hid/s3c24xx_ts/s3c24xx_ts.c

    rcde999a r84a1a54  
    8888        if (rc != EOK) {
    8989                printf("%s: Unable to register driver.\n", NAME);
    90                 return rc;
     90                return EXIT_RC(rc);
    9191        }
    9292
     
    9595                return -1;
    9696
    97         if (s3c24xx_ts_init(ts) != EOK)
     97        if (s3c24xx_ts_init(ts) != 0)
    9898                return -1;
    9999
     
    141141        s3c24xx_ts_wait_for_int_mode(ts, updn_down);
    142142
    143         return EOK;
     143        return 0;
    144144}
    145145
Note: See TracChangeset for help on using the changeset viewer.