rt->pd->scrollbottom = newbottom;
}
-static void interpret_csi_SAVECUR(RoteTerm *rt, int param[], int pcount)
+static void
+interpret_csi_SAVECUR(RoteTerm *rt,
+ int param[] __attribute__((unused)),
+ int pcount __attribute__((unused)))
{
rt->pd->saved_x = rt->ccol;
rt->pd->saved_y = rt->crow;
}
-static void interpret_csi_RESTORECUR(RoteTerm *rt, int param[], int pcount)
+static void
+interpret_csi_RESTORECUR(RoteTerm *rt,
+ int param[] __attribute__((unused)),
+ int pcount __attribute__((unused)))
{
rt->ccol = rt->pd->saved_x;
rt->crow = rt->pd->saved_y;
void *ptr = buf;
int i;
- for (i = 0; i < rt->rows; i++, ptr += bytes_per_row)
+ for (i = 0; i < rt->rows; i++) {
memcpy(ptr, rt->cells[i], bytes_per_row);
+ ptr = (char *)ptr + bytes_per_row;
+ }
return buf;
}
int i;
- for (i = 0; i < rt->rows; i++, snapbuf += bytes_per_row) {
+ for (i = 0; i < rt->rows; i++) {
rt->line_dirty[i] = true;
memcpy(rt->cells[i], snapbuf, bytes_per_row);
+ snapbuf = (char *)snapbuf + bytes_per_row;
}
}
/* Represents each of the text cells in the terminal screen */
typedef struct RoteCell_ {
- unsigned char ch; /* >= 32, that is, control characters are not
+ unsigned int ch; /* >= 32, that is, control characters are not
* allowed to be on the virtual screen */
unsigned char attr; /* a color attribute, as described previously */