diff --git a/src/demo/xray.c b/src/demo/xray.c index cdd64ee7a..f09460fdb 100644 --- a/src/demo/xray.c +++ b/src/demo/xray.c @@ -108,7 +108,6 @@ int xray_demo(struct notcurses* nc){ char* path = find_data("notcursesI.avi"); nc_err_e err; struct ncvisual* ncv = ncplane_visual_open(n, path, &err); -fprintf(stderr, "NCV: %p %s\n", ncv, path); free(path); if(ncv == NULL){ return -1; diff --git a/src/lib/libav.c b/src/lib/libav.c index 294b9dee7..337f9fc23 100644 --- a/src/lib/libav.c +++ b/src/lib/libav.c @@ -459,7 +459,7 @@ int ncvisual_stream(notcurses* nc, ncvisual* ncv, nc_err_e* ncerr, // each frame has a pkt_duration in milliseconds. keep the aggregate, in case // we don't have PTS available. uint64_t sum_duration = 0; - while(ncvisual_decode(ncv) == NCERR_SUCCESS){ + while((*ncerr = ncvisual_decode(ncv)) == NCERR_SUCCESS){ // codecctx seems to be off by a factor of 2 regularly. instead, go with // the time_base from the avformatctx. double tbase = av_q2d(ncv->fmtctx->streams[ncv->stream_index]->time_base);