mirror of
https://gitlab.rtems.org/rtems/rtos/rtems.git
synced 2026-02-04 04:31:36 +00:00
cpukit/libcsupport: Address -Wsign-compare warnings
This warning occurs when comparing a signed variable to an unsigned one. This addresses warnings that only occurred on 64-bit targets. For the ones which only appeared on 64-bit targets, the cause was frequently a mismatch when comparing a combination off_t, ssize_t, and int.
This commit is contained in:
@@ -134,7 +134,7 @@ scanInt(FILE *fp, int *val)
|
|||||||
int i = 0;
|
int i = 0;
|
||||||
int limit = INT_MAX;
|
int limit = INT_MAX;
|
||||||
int sign = 0;
|
int sign = 0;
|
||||||
int d;
|
unsigned int d;
|
||||||
|
|
||||||
for (;;) {
|
for (;;) {
|
||||||
c = getc(fp);
|
c = getc(fp);
|
||||||
|
|||||||
Reference in New Issue
Block a user