Date: Fri, 8 Jul 2011 19:47:18 +0300 From: Kostik Belousov <kostikbel@gmail.com> To: John <jwd@slowblink.com> Cc: freebsd-current@freebsd.org Subject: Re: kenv values with ansi escapte sequences - ansi_caption Message-ID: <20110708164718.GY48734@deviant.kiev.zoral.com.ua> In-Reply-To: <20110708145148.GA12548@FreeBSD.org> References: <20110708145148.GA12548@FreeBSD.org>
next in thread | previous in thread | raw e-mail | index | archive | help
--/kVOxs45Texhr2Rq Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Jul 08, 2011 at 02:51:48PM +0000, John wrote: > Hi Folks, >=20 > It seems the new pre-boot options selection process has > some values defined within the kernel environment that contain > ansi control sequences. For instance: >=20 > # kenv > LINES=3D"24" > ansi_caption[1]=3D"Boot [ENTER]" > ansi_caption[2]=3D"Escape to loader prompt" > ansi_caption[4]=3D"ACPI Support: Disabled" > ansi_caption[5]=3D"Boot Safe Mode: NO" > ansi_caption[6]=3D"Boot Single User: NO" > ansi_caption[7]=3D"Boot Verbose: NO" > bootfile=3D"kernel" >=20 > Using less, od -c, or other utility, we have: >=20 > # kenv | less > LINES=3D"24" > ansi_caption[1]=3D"ESC[1mBESC[37moot ESC[1m[ENTER]ESC[37m" > ansi_caption[2]=3D"ESC[1mEscESC[37mape to loader prompt" > ansi_caption[4]=3D"ESC[1mAESC[37mCPI Support: ESC[34;1mDisabledESC[37m" > ansi_caption[5]=3D"Boot Safe ESC[1mMESC[37mode: ESC[34;1mNOESC[37m" > ansi_caption[6]=3D"Boot ESC[1mSESC[37mingle User: ESC[34;1mNOESC[37m" > ansi_caption[7]=3D"Boot ESC[1mVESC[37merbose: ESC[34;1mNOESC[37m" > bootfile=3D"kernel" >=20 > This caused a few issues with a script that parses the > output of kenv. Simple enough to fix, but thought I'd see > what others think. >=20 > Thoughts? Opinions? I think the right question there is why the variables are leaked into the kenv at all. They should be removed. --/kVOxs45Texhr2Rq Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (FreeBSD) iEYEARECAAYFAk4XNJUACgkQC3+MBN1Mb4hYCgCcCht/ZoX8+lnaLosx/BNb0MCz JnkAoLfOFr/7gXWDZ+SQCPKIIHfCe7Mg =CKDg -----END PGP SIGNATURE----- --/kVOxs45Texhr2Rq--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20110708164718.GY48734>