From: Keith Packard Date: Mon, 2 Oct 2017 23:57:15 +0000 (-0700) Subject: altos: Allow pyro config name to end with newline, not just space/tab X-Git-Tag: 1.8.3~1^2~82 X-Git-Url: https://git.gag.com/?p=fw%2Faltos;a=commitdiff_plain;h=770998be2c15dd41a63520d0c8747d7cf32ec447 altos: Allow pyro config name to end with newline, not just space/tab A pyro config like 'Descending' has no value associated. When it is at the end of the line, allow a newline to terminate the name instead of just a space. Signed-off-by: Keith Packard --- diff --git a/src/kernel/ao_pyro.c b/src/kernel/ao_pyro.c index 9543b3ef..0aed50d5 100644 --- a/src/kernel/ao_pyro.c +++ b/src/kernel/ao_pyro.c @@ -482,7 +482,7 @@ ao_pyro_set(void) break; for (c = 0; c < AO_PYRO_NAME_LEN - 1; c++) { - if (ao_cmd_is_white()) + if (ao_cmd_is_white() || ao_cmd_lex_c == '\n') break; name[c] = ao_cmd_lex_c; ao_cmd_lex();