break;
}
- if (pos - start_offset > 0)
+ if (pos > start_offset)
printbuf_memappend(pb, str + start_offset, pos - start_offset);
if (c == '\b')
if (c < ' ')
{
char sbuf[7];
- if (pos - start_offset > 0)
+ if (pos > start_offset)
printbuf_memappend(pb, str + start_offset,
pos - start_offset);
snprintf(sbuf, sizeof(sbuf), "\\u00%c%c", json_hex_chars[c >> 4],
pos++;
}
}
- if (pos - start_offset > 0)
+ if (pos > start_offset)
printbuf_memappend(pb, str + start_offset, pos - start_offset);
return 0;
}