From: Vinson Lee Date: Thu, 3 Nov 2011 07:36:27 +0000 (-0700) Subject: i965: Fix Coverity wrong sizeof argument defect. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=3e18ad7fd7026e31fd92fe5cf7097d08e5b9a15a;p=mesa.git i965: Fix Coverity wrong sizeof argument defect. NOTE: This is a candidate for stable release branches. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=42542 Reviewed-by: Kenneth Graunke --- diff --git a/src/mesa/drivers/dri/i965/gen7_viewport_state.c b/src/mesa/drivers/dri/i965/gen7_viewport_state.c index 252a35b21fc..d0b89d5fe57 100644 --- a/src/mesa/drivers/dri/i965/gen7_viewport_state.c +++ b/src/mesa/drivers/dri/i965/gen7_viewport_state.c @@ -38,7 +38,7 @@ gen7_upload_sf_clip_viewport(struct brw_context *brw) struct gen7_sf_clip_viewport *vp; vp = brw_state_batch(brw, AUB_TRACE_SF_VP_STATE, - sizeof(vp), 64, &brw->sf.vp_offset); + sizeof(*vp), 64, &brw->sf.vp_offset); /* Also assign to clip.vp_offset in case something uses it. */ brw->clip.vp_offset = brw->sf.vp_offset;