Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 9 May 2021 16:06:19 GMT
From:      Xin LI <delphij@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org
Subject:   git: 8725f0b9dbd2 - main - Revert "getty: push assignment to inner block."
Message-ID:  <202105091606.149G6Jdh002331@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by delphij:

URL: https://cgit.FreeBSD.org/src/commit/?id=8725f0b9dbd296ca93f0f19c51940a46a98dcb2d

commit 8725f0b9dbd296ca93f0f19c51940a46a98dcb2d
Author:     Xin LI <delphij@FreeBSD.org>
AuthorDate: 2021-05-09 16:05:52 +0000
Commit:     Xin LI <delphij@FreeBSD.org>
CommitDate: 2021-05-09 16:05:52 +0000

    Revert "getty: push assignment to inner block."
    
    This reverts commit c7b8bc367f18210d233b0e2185b5ce0d55c9ccaa.
    
    Pointed out by: trasz
---
 libexec/getty/subr.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libexec/getty/subr.c b/libexec/getty/subr.c
index b8f359355afc..9958d193aa60 100644
--- a/libexec/getty/subr.c
+++ b/libexec/getty/subr.c
@@ -564,8 +564,8 @@ makeenv(char *env[])
 		strlcat(termbuf, TT, sizeof(termbuf));
 		*ep++ = termbuf;
 	}
-	if (EV) {
-		p = EV;
+	if ((p = EV)) {
+		q = p;
 		while ((q = strchr(q, ','))) {
 			*q++ = '\0';
 			*ep++ = p;



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202105091606.149G6Jdh002331>