renderer: bail if we don't have a program when we need it.

This is just avoiding a crash, it really shouldn't happen,
but we don't want to crash if it does.
macos/master
Dave Airlie 9 years ago
parent 4385520930
commit dd4345b5af
  1. 5
      src/vrend_renderer.c

@ -2546,7 +2546,10 @@ void vrend_draw_vbo(struct vrend_context *ctx,
ctx->sub->prog = prog;
}
}
if (!ctx->sub->prog) {
fprintf(stderr,"dropping rendering due to missing shaders: %s\n", ctx->debug_name);
return;
}
glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, ctx->sub->fb_id);
vrend_use_program(ctx, ctx->sub->prog->id);

Loading…
Cancel
Save