diff options
author | H. Peter Anvin <hpa@zytor.com> | 2006-09-14 16:26:07 -0700 |
---|---|---|
committer | H. Peter Anvin <hpa@zytor.com> | 2006-09-14 16:26:07 -0700 |
commit | dd5f204f879e3bc7b0fc9b682ea855c7dd499601 (patch) | |
tree | 178161872b85c6612c2bbcc8e78fee10496f15bb /com32 | |
parent | 9b41f832015ec8cf77c471e091237e97af397818 (diff) | |
download | syslinux-dd5f204f879e3bc7b0fc9b682ea855c7dd499601.tar.gz |
Allow specifying * instead of any of the MENU COLOR fields.syslinux-3.30-pre8
Diffstat (limited to 'com32')
-rw-r--r-- | com32/modules/readconfig.c | 22 |
1 files changed, 16 insertions, 6 deletions
diff --git a/com32/modules/readconfig.c b/com32/modules/readconfig.c index 0a779568..24057b1b 100644 --- a/com32/modules/readconfig.c +++ b/com32/modules/readconfig.c @@ -420,15 +420,25 @@ void parse_config(const char *filename) if ( (ep = looking_at(p, cptr->name)) ) { p = skipspace(ep); if (*p) { - free(cptr->ansi); - cptr->ansi = dup_word(&p); + if (!strcmp(p, "*")) { + p++; + } else { + free((void *)cptr->ansi); + cptr->ansi = dup_word(&p); + } - p = skipspace(ep); + p = skipspace(p); if (*p) { - cptr->argb_fg = parse_argb(&p); - p = skipspace(ep); + if (!strcmp(p, "*")) { + p++; + } else { + cptr->argb_fg = parse_argb(&p); + } + + p = skipspace(p); if (*p) { - cptr->argb_bg = parse_argb(&p); + if (strcmp(p, "*")) + cptr->argb_bg = parse_argb(&p); } } } |