[PATCH libxkbcommon 08/11] Fix all constness warnings

Daniel Stone daniel at fooishbar.org
Tue Feb 28 11:04:31 PST 2012


Hi,

On 28 February 2012 18:27, Ran Benita <ran234 at gmail.com> wrote:
> Running the following semantic patch:
>
> @@
> expression E;
> @@
> - if (E != NULL)
> -     free(E);
> + free(E);
>
> Gives this:
> [...]
>
> And probably doesn't catch all of them. So maybe I can send this as a
> separate patch later?

Yes, please, that'd be fine.  You might also want to add if (!E) to your checks.

Cheers,
Daniel


More information about the xorg-devel mailing list