On Friday, 2017-09-01 15:40:52 +0100, Eric Engestrom wrote:
> On Friday, 2017-09-01 14:07:43 +0200, Samuel Pitoiset wrote:
> > Found by inspection.
> > 
> > Signed-off-by: Samuel Pitoiset <[email protected]>
> > ---
> >  src/amd/vulkan/radv_pipeline.c | 3 +++
> >  1 file changed, 3 insertions(+)
> > 
> > diff --git a/src/amd/vulkan/radv_pipeline.c b/src/amd/vulkan/radv_pipeline.c
> > index f2d1b491b7..858cc54085 100644
> > --- a/src/amd/vulkan/radv_pipeline.c
> > +++ b/src/amd/vulkan/radv_pipeline.c
> > @@ -618,6 +618,9 @@ radv_pipeline_compile(struct radv_pipeline *pipeline,
> >                                                               gs_copy_code,
> >                                                               
> > gs_copy_code_size);
> >             }
> > +
> > +           if (gs_copy_code)
> > +                   free(gs_copy_code);
> 
> No need for the `if` guard, free(NULL) is a noop.

Sorry, sent too quickly; with the `if` removed, this is:
Reviewed-by: Eric Engestrom <[email protected]>

> 
> >     }
> >     if (!module->nir)
> >             ralloc_free(nir);
> > -- 
> > 2.14.1
> > 
_______________________________________________
mesa-dev mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to