notcurses_debug: handle bound planes

This commit is contained in:
nick black 2020-06-03 09:02:37 -04:00
parent d41c6d3627
commit bc6305b08e
No known key found for this signature in database
GPG Key ID: 5F43400C21CBFACC

View File

@ -9,14 +9,14 @@ void notcurses_debug(notcurses* nc, FILE* debugfp){
fprintf(debugfp, "%04d off y: %3d x: %3d geom y: %3d x: %3d curs y: %3d x: %3d %s %p\n",
planeidx, n->absy, n->absx, n->leny, n->lenx, n->y, n->x,
n == notcurses_stdplane_const(nc) ? "std" : " ", n);
if(n->bound || n->bnext || *n->bprev){
if(n->bound || n->bnext || n->bprev){
fprintf(debugfp, " bound to %p, next bound %p, bind %p\n",
n->bound, n->bnext, *n->bprev);
n->bound, n->bnext, n->bprev);
}
if(n->bnext == n || n->bound == n){
fprintf(debugfp, "WARNING: bound pointers target self\n");
}
if(*n->bprev != n){
if(n->bprev && (*n->bprev != n)){
fprintf(stderr, " WARNING: expected *->bprev %p, got %p\n", n, *n->bprev);
}
if(n->above != prev){