Skip to content

Commit

Permalink
use fgetwc on wide oriented streams
Browse files Browse the repository at this point in the history
  • Loading branch information
Szabolcs Nagy committed Apr 10, 2015
1 parent c8999dd commit 84bd22c
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/functional/fwscanf.c
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ int main(void)
TEST(i, y, 12, "%d != %d");
TEST(i, ftell(f), 12, "%d != %d");
TEST(i, feof(f), 0, "%d != %d");
TEST(i, fgetc(f), 'x', "%d != %d");
TEST(i, fgetwc(f), 'x', "%d != %d");
fclose(f);
}

Expand All @@ -74,10 +74,10 @@ int main(void)
TEST(i, y, -1, "%d != %d");
TEST(i, ftell(f), 4, "%d != %d");
TEST(i, feof(f), 0, "%d != %d");
TEST(i, fgetc(f), ' ', "%d != %d");
TEST(i, fgetwc(f), ' ', "%d != %d");
rewind(f);
TEST(i, fgetc(f), '0', "%d != %d");
TEST(i, fgetc(f), 'x', "%d != %d");
TEST(i, fgetwc(f), '0', "%d != %d");
TEST(i, fgetwc(f), 'x', "%d != %d");
TEST(i, fwscanf(f, L"%lf%n%c %d", &u, &x, a, &y), 3, "%d != %d");
TEST(u, u, 1.0, "%g != %g");
TEST(i, x, 1, "%d != %d");
Expand Down

0 comments on commit 84bd22c

Please sign in to comment.