…and use it for ignoring comment lines, so that quotes in them
doesn't cause problems anymore.
# We ignore comments and 'set' lines (variables).
state IGNORE_LINE:
- end, string
+ line
-> INITIAL
# floating_minimum_size <width> x <height>
# We ignore comments and 'set' lines (variables).
state MODE_IGNORE_LINE:
- end, string
+ line
-> MODE
state MODE_BINDING:
# We ignore comments and 'set' lines (variables).
state BAR_IGNORE_LINE:
- end, string
+ line
-> BAR
state BAR_BAR_COMMAND:
# We ignore comments and 'set' lines (variables).
state BAR_COLORS_IGNORE_LINE:
- end, string
+ line
-> BAR_COLORS
state BAR_COLORS_SINGLE:
}
}
+ if (strcmp(token->name, "line") == 0) {
+ while (*walk != '\0' && *walk != '\n' && *walk != '\r')
+ walk++;
+ next_state(token);
+ token_handled = true;
+ linecnt++;
+ walk++;
+ break;
+ }
+
if (strcmp(token->name, "end") == 0) {
//printf("checking for end: *%s*\n", walk);
if (*walk == '\0' || *walk == '\n' || *walk == '\r') {