# HG changeset patch # User Michael Pavone # Date 1484522972 28800 # Node ID fa73a77ddf9222ae7cd93d76ec1e06aeff3fc08d # Parent e758ddbf0624ba6a855300506b927f8a0e1d610c Fix benchmark mode diff -r e758ddbf0624 -r fa73a77ddf92 vdp.c --- a/vdp.c Sun Jan 15 15:07:24 2017 -0800 +++ b/vdp.c Sun Jan 15 15:29:32 2017 -0800 @@ -112,7 +112,7 @@ /* */ if (headless) { - context->output = malloc(LINEBUF_SIZE); + context->output = malloc(LINEBUF_SIZE * sizeof(uint32_t)); context->output_pitch = 0; } else { context->fb = render_get_framebuffer(FRAMEBUFFER_ODD, &context->output_pitch); @@ -1456,6 +1456,9 @@ context->vcounter = 0x1D5; } if (headless) { + if (context->vcounter == context->inactive_start) { + context->frame++; + } context->vcounter &= 0x1FF; } else { if (context->vcounter == context->inactive_start) {