diff options
author | Ulrich Drepper <drepper@redhat.com> | 1996-10-02 01:40:17 +0000 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 1996-10-02 01:40:17 +0000 |
commit | a68b0d31a37a86785b3dbeeee3fad96ee71fadcd (patch) | |
tree | 61537b1f028002a9e6e0f5354fced6128bda8b9c /libio/strops.c | |
parent | 2d07133b507b13d4a5ed6dc250f4345c8a26942a (diff) | |
download | glibc-a68b0d31a37a86785b3dbeeee3fad96ee71fadcd.tar.gz |
update from main archive 961001
Diffstat (limited to 'libio/strops.c')
-rw-r--r-- | libio/strops.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/libio/strops.c b/libio/strops.c index 98c5b263d5..464063322d 100644 --- a/libio/strops.c +++ b/libio/strops.c @@ -1,4 +1,4 @@ -/* +/* Copyright (C) 1993 Free Software Foundation This file is part of the GNU IO Library. This library is free @@ -112,7 +112,7 @@ DEFUN(_IO_str_overflow, (fp, c), fp->_flags |= _IO_CURRENTLY_PUTTING; get_pos = LEN(fp); } - if (pos >= _IO_blen(fp) + flush_only) + if (pos >= (_IO_size_t) (_IO_blen(fp) + flush_only)) { if (fp->_flags & _IO_USER_BUF) /* not allowed to enlarge */ { @@ -187,10 +187,10 @@ DEFUN(_IO_str_count, (fp), register _IO_FILE *fp) { _IO_ssize_t put_len = fp->_IO_write_ptr - fp->_IO_write_base; - if (put_len < LEN(fp)) + if (put_len < (_IO_ssize_t) LEN(fp)) put_len = LEN(fp); return put_len; -} +} _IO_pos_t DEFUN(_IO_str_seekoff, (fp, offset, dir, mode), @@ -213,7 +213,7 @@ DEFUN(_IO_str_seekoff, (fp, offset, dir, mode), default: /* case _IO_seek_set: */ break; } - if (offset < 0 || (_IO_size_t)offset > cur_size) + if (offset < 0 || (_IO_ssize_t)offset > cur_size) return EOF; fp->_IO_read_ptr = fp->_IO_read_base + offset; fp->_IO_read_end = fp->_IO_read_base + cur_size; @@ -234,7 +234,7 @@ DEFUN(_IO_str_seekoff, (fp, offset, dir, mode), default: /* case _IO_seek_set: */ break; } - if (offset < 0 || (_IO_size_t)offset > cur_size) + if (offset < 0 || (_IO_ssize_t)offset > cur_size) return EOF; LEN(fp) = cur_size; fp->_IO_write_ptr = fp->_IO_write_base + offset; |