renderer: fix potential leak

Found thanks to llvm scan-build.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
macos/master
Marc-André Lureau 9 years ago committed by Dave Airlie
parent 8030fdbd92
commit 2a4d35b8b3
  1. 1
      src/vrend_renderer.c

@ -5039,6 +5039,7 @@ void vrend_set_streamout_targets(struct vrend_context *ctx,
target = vrend_object_lookup(ctx->sub->object_hash, handles[i], VIRGL_OBJECT_STREAMOUT_TARGET);
if (!target) {
report_context_error(ctx, VIRGL_ERROR_CTX_ILLEGAL_HANDLE, handles[i]);
free(obj);
return;
}
vrend_so_target_reference(&obj->so_targets[i], target);

Loading…
Cancel
Save