[U-Boot] [PATCH] Ignore all Carriage Returns when importing an environment.
Alexander Holler
holler at ahsoftware.de
Sat May 12 16:22:42 CEST 2012
Am 11.05.2012 21:09, schrieb Wolfgang Denk:
> Dear Alexander Holler,
>
> In message<1336720486-7424-1-git-send-email-holler at ahsoftware.de> you wrote:
>> This is used for compatibility with text files which are
>> using CRLF instead of LF as the end of a line.
>
> I don't think we should do this. If you have text files with CR-LF
> line endings, then please use external tools (like dos2unix) to filter
> these and bring them into the appropriate format.
>
> I would like to put as little restrictions on the content of an
> environment variable as possible. I can see valid use for strings
> that contain a CR character.
I don't see any reasonable usage for carriage returns in imported
environment variables, but I've seen many people from the windows camp
struggling in writing small text files to set some environment variables
(which mostly end up in the kernel cmdline). Especially because those
CR's often will lead to obscure errors because almost nothing (in u-boot
or linux) is able to handle them.
Anyway I don't really care, I just found it very user friendly to strip
the carriage returns, especially for those embedded newbies which are in
need to use some unnamed windows IDE.
So I've decided (after having that patch lying around for about a year)
to finally post it.
Regards,
Alexander
More information about the U-Boot
mailing list