i965: miptree: silence coverity warning
authorLionel Landwerlin <lionel.g.landwerlin@intel.com>
Sun, 16 Jul 2017 14:17:25 +0000 (15:17 +0100)
committerLionel Landwerlin <lionel.g.landwerlin@intel.com>
Mon, 17 Jul 2017 13:36:38 +0000 (14:36 +0100)
This probably can't happen, but we're better off with initialized
variables.

CID: 1415114
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com>
src/mesa/drivers/dri/i965/intel_mipmap_tree.c

index e7ebc29b59d690235b64769589c53a4a8d03a9bd..83d3d8204aa196128c0146505d8421b623392bc4 100644 (file)
@@ -990,7 +990,7 @@ miptree_create_for_planar_image(struct brw_context *brw,
                                 __DRIimage *image, GLenum target)
 {
    struct intel_image_format *f = image->planar_format;
-   struct intel_mipmap_tree *planar_mt;
+   struct intel_mipmap_tree *planar_mt = NULL;
 
    for (int i = 0; i < f->nplanes; i++) {
       const int index = f->planes[i].buffer_index;