diff options
| author | Jakob Kaivo <jkk@ung.org> | 2024-02-02 13:56:33 -0500 |
|---|---|---|
| committer | Jakob Kaivo <jkk@ung.org> | 2024-02-02 13:56:33 -0500 |
| commit | 8b3f2fa09e9241e20926c8171753a271c21ec93d (patch) | |
| tree | a8bdff34505bfcf999467053dbfbf276bf7233f1 /src/stdio/fseek.c | |
| parent | 3a9026cf8557c8efec34e652b6bf37ce49f12f86 (diff) | |
first cut of tracking previous return values with ftell()/fseek() as POC
Diffstat (limited to 'src/stdio/fseek.c')
| -rw-r--r-- | src/stdio/fseek.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/stdio/fseek.c b/src/stdio/fseek.c index 47388c9a..9f4bd733 100644 --- a/src/stdio/fseek.c +++ b/src/stdio/fseek.c @@ -12,8 +12,7 @@ int fseek(FILE *stream, long int offset, int whence) if (whence != SEEK_SET) { UNDEFINED("In call to fseek(): Only SEEK_SET is supported for text files"); } - /* if offset is not previous */ - /* UNDEFINED("fseek() on text files requires an offset previously returned by ftell()"); */ + ASSERT_PREV(offset, stream->valid_ftell, stream->nvalid_ftell, "ftell"); } if (whence == SEEK_CUR) { |
