diff options
Diffstat (limited to 'lib/libc/stdio/fseek.c')
-rw-r--r-- | lib/libc/stdio/fseek.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/lib/libc/stdio/fseek.c b/lib/libc/stdio/fseek.c index a5a9f30..aa886d2 100644 --- a/lib/libc/stdio/fseek.c +++ b/lib/libc/stdio/fseek.c @@ -256,17 +256,13 @@ _fseeko(fp, offset, whence, ltest) fp->_p -= curoff; fp->_r += curoff; curoff = 0; - } else { - errno = EBADF; - return (-1); - } + } else + goto dumb; } if (HASUB(fp)) { curoff -= fp->_ur; - if (curoff < 0) { - errno = EBADF; - return (-1); - } + if (curoff < 0) + goto dumb; } } |