Skip to contentSkip to conversation

intel: Use VG_CLEAR on the context destroy ioctl as well.

PATCH In review Kenneth Graunke 2 participants 2 messages Aug 12, 2012 – Aug 13, 2012

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 intel: Use VG_CLEAR on the context destroy ioctl as well.

Otherwise pad appears uninitialized and valgrind grumbles.

---
 intel/intel_bufmgr_gem.c | 2 ++
 1 file changed, 2 insertions(+)
intel/intel_bufmgr_gem.c +2 -0
index a170813..795c1a8 100644
@@ -2936,6 +2936,8 @@ drm_intel_gem_context_destroy(drm_intel_context *ctx)
 	if (ctx == NULL)
 		return;
 
+	VG_CLEAR(destroy);
+
 	bufmgr_gem = (drm_intel_bufmgr_gem *)ctx->bufmgr;
 	destroy.ctx_id = ctx->ctx_id;
 	ret = drmIoctl(bufmgr_gem->fd, DRM_IOCTL_I915_GEM_CONTEXT_DESTROY,
Signature · 1 line
1.7.11.4