[git commit] getpass: s/sizeof(buf)-1/sizeof(buf)/ in fgets
Denys Vlasenko
vda.linux at googlemail.com
Sun Jan 1 16:31:40 UTC 2012
commit: http://git.uclibc.org/uClibc/commit/?id=d5fd9afa76176c889196bb0631bfed77431b295d
branch: http://git.uclibc.org/uClibc/commit/?id=refs/heads/master
Signed-off-by: Denys Vlasenko <vda.linux at googlemail.com>
---
libc/unistd/getpass.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/libc/unistd/getpass.c b/libc/unistd/getpass.c
index dd927ab..c311a15 100644
--- a/libc/unistd/getpass.c
+++ b/libc/unistd/getpass.c
@@ -75,7 +75,7 @@ char * getpass (const char *prompt)
fflush(out);
/* Read the password. */
- if (!fgets (buf, sizeof(buf)-1, in))
+ if (!fgets (buf, sizeof(buf), in))
buf[0] = '\0';
nread = strlen(buf);
if (nread > 0 && buf[nread - 1] == '\n')
More information about the uClibc-cvs
mailing list