csi: fix wrong variable compared in for-loop

This commit is contained in:
Daniel Eklöf 2019-07-18 14:13:35 +02:00
parent 0c565d1558
commit b6b92a742d
No known key found for this signature in database
GPG key ID: 5BBD4992C116573F

2
csi.c
View file

@ -128,7 +128,7 @@ csi_as_string(struct terminal *term, uint8_t final)
c += snprintf(&msg[c], sizeof(msg) - c, "%d",
term->vt.params.v[i].value);
for (size_t j = 0; i < term->vt.params.v[i].sub.idx; j++) {
for (size_t j = 0; j < term->vt.params.v[i].sub.idx; j++) {
c += snprintf(&msg[c], sizeof(msg) - c, ":%d",
term->vt.params.v[i].sub.value[j]);
}