Fix [f]getc return value usage in 40_stdio test
Store [f]getc return value into an int instead of char, as per prototype. This fix an issue when char is unsigned (as is on arm for both tcc and gcc).
This commit is contained in:
@ -16,7 +16,7 @@ int main()
|
|||||||
|
|
||||||
printf("%s", freddy);
|
printf("%s", freddy);
|
||||||
|
|
||||||
char InChar;
|
int InChar;
|
||||||
char ShowChar;
|
char ShowChar;
|
||||||
f = fopen("fred.txt", "r");
|
f = fopen("fred.txt", "r");
|
||||||
while ( (InChar = fgetc(f)) != EOF)
|
while ( (InChar = fgetc(f)) != EOF)
|
||||||
|
|||||||
Reference in New Issue
Block a user