From c630fae7b18ec399c45305737f10ab47733dc63e Mon Sep 17 00:00:00 2001 From: Andre Noll Date: Thu, 22 Oct 2009 22:50:58 +0200 Subject: [PATCH] populate_user_list(): Use correct buffer size. "line" is defined as a 255 byte buffer. Use sizeof(line) rather than MAXLINE in the call to para_fgets(). This is not a real bug though as MAXLINE happens to be 255 as well. --- user_list.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/user_list.c b/user_list.c index 63bfdfc2..f5aabc09 100644 --- a/user_list.c +++ b/user_list.c @@ -39,7 +39,7 @@ static void populate_user_list(char *user_list_file) struct user *u; RSA *rsa; - ret = para_fgets(line, MAXLINE, file_ptr); + ret = para_fgets(line, sizeof(line), file_ptr); if (ret <= 0) break; if (sscanf(line,"%200s %200s %200s %200s", w, n, k, p) < 3) -- 2.39.2