From a0e3c9e2e8ec0147a54cbc2f628c345f9f7ddfb7 Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Tue, 1 Mar 2005 01:20:39 +0000 Subject: * debug/read_chk.c (__read_chk): Always fail if the buffer is too small. * debug/readlink_chk.c (__readlink_chk): Likewise. * debug/pread64_chk.c (__pread64_chk): Likewise. * debug/pread_chk.c (__pread_chk): Likewise. --- debug/read_chk.c | 4 ++-- debug/readlink_chk.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'debug') diff --git a/debug/read_chk.c b/debug/read_chk.c index f738c48d6b..da2bc945b7 100644 --- a/debug/read_chk.c +++ b/debug/read_chk.c @@ -31,8 +31,8 @@ __read_chk (int fd, void *buf, size_t nbytes, size_t buflen) __chk_fail (); #ifdef HAVE_INLINED_SYSCALLS - return = INLINE_SYSCALL (read, 3, fd, buf, nbytes); + return INLINE_SYSCALL (read, 3, fd, buf, nbytes); #else - return = __read (fd, buf, nbytes); + return __read (fd, buf, nbytes); #endif } diff --git a/debug/readlink_chk.c b/debug/readlink_chk.c index d8d61dc699..ac18ee2c29 100644 --- a/debug/readlink_chk.c +++ b/debug/readlink_chk.c @@ -31,8 +31,8 @@ __readlink_chk (const char *path, void *buf, size_t len, size_t buflen) __chk_fail (); #ifdef HAVE_INLINED_SYSCALLS - return INLINE_SYSCALL (readlink, 3, path, buf, MIN (len, buflen + 1)); + return INLINE_SYSCALL (readlink, 3, path, buf, len); #else - return __readlink (path, buf, MIN (len, buflen + 1)); + return __readlink (path, buf, len); #endif } -- cgit 1.4.1