PandABlocks / PandABlocks-rootfs

Root filesystem build with tools for building zpg packages
Apache License 2.0
3 stars 5 forks source link

Do windows line endings on config.txt screw things up? #10

Closed thomascobb closed 3 years ago

thomascobb commented 3 years ago

A PandA user has a "HOSTNAME = something\r\r\n" in their file, and hostname is not getting set. Are these things related?

Araneidae commented 3 years ago

I'm afraid that \r is not a recognised character. They're trying to set HOSTNAME to "something\r\r", and this is probably an invalid host name.

Validating config.txt is difficult to do at startup: what do we do when it's bad? And we don't have the option to validate it earlier either.

maybe the sed script could be amended to discard [\r\s\t]*$ as well?