mirror of
https://github.com/dankamongmen/notcurses
synced 2025-03-10 01:29:05 -04:00
[sixel_delete] don't scribble beyond pile rendering vector #1534
This commit is contained in:
parent
e591ec2e98
commit
81370ba311
@ -505,8 +505,8 @@ int sixel_delete(const notcurses* nc, const ncpile* p, FILE* out, sprixel* s){
|
|||||||
//fprintf(stderr, "%d] %d %p\n", s->id, s->invalidated, s->n);
|
//fprintf(stderr, "%d] %d %p\n", s->id, s->invalidated, s->n);
|
||||||
(void)nc;
|
(void)nc;
|
||||||
(void)out;
|
(void)out;
|
||||||
for(int yy = s->movedfromy ; yy < s->movedfromy + s->dimy ; ++yy){
|
for(int yy = s->movedfromy ; yy < s->movedfromy + s->dimy && yy < p->dimy ; ++yy){
|
||||||
for(int xx = s->movedfromx ; xx < s->movedfromx + s->dimx ; ++xx){
|
for(int xx = s->movedfromx ; xx < s->movedfromx + s->dimx && xx < p->dimx ; ++xx){
|
||||||
struct crender *r = &p->crender[yy * p->dimx + xx];
|
struct crender *r = &p->crender[yy * p->dimx + xx];
|
||||||
if(!r->sprixel){
|
if(!r->sprixel){
|
||||||
r->s.damaged = 1;
|
r->s.damaged = 1;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user