This is awkward.

This commit is contained in:
LemonBoy 2013-08-31 16:54:02 +00:00
parent 3a207cf9ba
commit 216162c7eb

9
bar.c
View File

@ -145,13 +145,16 @@ parse (char *text)
if (*p == '\\' && p++ && *p != '\\' && strchr ("fbulcr", *p)) { if (*p == '\\' && p++ && *p != '\\' && strchr ("fbulcr", *p)) {
switch (*p++) { switch (*p++) {
case 'f': case 'f':
xcb_set_fg (!isdigit(*p) ? (*p++)-'0' : 11); xcb_set_fg (isdigit(*p) ? (*p)-'0' : 11);
p++;
break; break;
case 'b': case 'b':
xcb_set_bg (!isdigit(*p) ? (*p++)-'0' : 10); xcb_set_bg (isdigit(*p) ? (*p)-'0' : 10);
p++;
break; break;
case 'u': case 'u':
xcb_set_ud (!isdigit(*p) ? (*p++)-'0' : 10); xcb_set_ud (isdigit(*p) ? (*p)-'0' : 10);
p++;
break; break;
case 'l': case 'l':