ostree-init: Also trim trailing newline from arguments
Otherwise the parsed argument is corrupted.
This commit is contained in:
parent
bfd47eb93a
commit
fb98d0bf24
|
|
@ -79,6 +79,9 @@ parse_arg (const char *cmdline, const char *arg)
|
||||||
const char *start = p + arglen;
|
const char *start = p + arglen;
|
||||||
const char *end = strchr (start, ' ');
|
const char *end = strchr (start, ' ');
|
||||||
|
|
||||||
|
if (!end)
|
||||||
|
end = strchr (start, '\n');
|
||||||
|
|
||||||
if (is_eq)
|
if (is_eq)
|
||||||
{
|
{
|
||||||
if (end)
|
if (end)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue