Accept when comments are indented, trim the whitespace from text lines
after stripping off the comment. This avoids the processing of lines
which actually are empty, and improves robustness (avoids errors for a
non-fatal situation). Also results in more appropriate diagnostics at
higher log levels.
if (!prefix->len)
return;
- if ((ptr = strstr(buf, prefix->str)))
+ if ((ptr = strstr(buf, prefix->str))) {
*ptr = '\0';
+ g_strstrip(buf);
+ }
}
static int parse_binstr(const char *str, struct context *inc)