From f9024c4d4663688db707bf3b966e9e965765f101 Mon Sep 17 00:00:00 2001 From: matthieu Date: Sun, 28 Oct 2018 19:38:19 +0000 Subject: [PATCH] Pass the correct buffer length to strlcpy() to avoid truncation. Problem noticed by Edgar Pettijohn III, ok tb@ --- app/xenodm/greeter/Login.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/xenodm/greeter/Login.c b/app/xenodm/greeter/Login.c index ce4e8a4b5..6ac176507 100644 --- a/app/xenodm/greeter/Login.c +++ b/app/xenodm/greeter/Login.c @@ -754,7 +754,7 @@ SetPrompt (Widget ctx, int promptNum, const char *message, return -1; } - strlcpy(prompt, message, messageLen); + strlcpy(prompt, message, messageLen + 3); /* Make sure text prompts have at least two spaces at end */ e = messageLen;