diff options
author | Clement Leger <cleger@kalray.eu> | 2020-03-20 17:07:20 +0100 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2020-03-23 08:19:03 +0100 |
commit | 8fb804c55b8ddf8edbf73489ee062f7d437adcf6 (patch) | |
tree | 9ab85fd7e25a273208058da9f2e7d1771a62e9e9 /common/memtest.c | |
parent | ce70a158ccf3da0d025d5f7059229a659b329ff2 (diff) | |
download | barebox-8fb804c55b8ddf8edbf73489ee062f7d437adcf6.tar.gz barebox-8fb804c55b8ddf8edbf73489ee062f7d437adcf6.tar.xz |
common: oftree: trim leading spaces from bootargs
When barebox concatenates all dynamic bootargs string for linux, if they
are empty, the resulting string might be composed of only spaces.
Currently, there is no check for such string and it leads to
overwriting bootargs in the device tree by an empty string. To avoid
this behavior, use skip_spaces to trim leading spaces and then check if
the string is empty. If so, simply returns and don't patch device tree
bootargs.
Signed-off-by: Clement Leger <cleger@kalray.eu>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'common/memtest.c')
0 files changed, 0 insertions, 0 deletions