nvc0: bsp_bo can't be null
authorIlia Mirkin <imirkin@alum.mit.edu>
Sun, 17 Jan 2016 08:41:55 +0000 (03:41 -0500)
committerIlia Mirkin <imirkin@alum.mit.edu>
Sun, 17 Jan 2016 21:37:04 +0000 (16:37 -0500)
We already deref it earlier. And these are all allocated on load.
Spotted by Coverity.

Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
src/gallium/drivers/nouveau/nvc0/nvc0_video_bsp.c

index c53f946a762239f217cab8dfff1d394519d039ea..af072a8acdc464619094c422f562966d4b360940 100644 (file)
@@ -64,7 +64,7 @@ nvc0_decoder_bsp_next(struct nouveau_vp3_decoder *dec,
       bsp_size += num_bytes[i];
    bsp_size += 256; /* the 4 end markers */
 
-   if (!bsp_bo || bsp_size > bsp_bo->size) {
+   if (bsp_size > bsp_bo->size) {
       union nouveau_bo_config cfg;
       struct nouveau_bo *tmp_bo = NULL;