[PATCH] randr: return NULL instead of FALSE

Olivier Fourdan ofourdan at redhat.com
Mon Nov 23 02:28:10 PST 2015


> No functional change since FALSE = (0) and NULL = ((void *) 0),
> but everywhere else in that function we return NULL
> 
> Signed-off-by: Marek Chalupa <mchqwerty at gmail.com>
> ---
>  randr/rrcrtc.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/randr/rrcrtc.c b/randr/rrcrtc.c
> index 9bc456b..c9f9254 100644
> --- a/randr/rrcrtc.c
> +++ b/randr/rrcrtc.c
> @@ -70,7 +70,7 @@ RRCrtcCreate(ScreenPtr pScreen, void *devPrivate)
>      else
>          crtcs = malloc(sizeof(RRCrtcPtr));
>      if (!crtcs)
> -        return FALSE;
> +        return NULL;
>      pScrPriv->crtcs = crtcs;
>  
>      crtc = calloc(1, sizeof(RRCrtcRec));

This looks obviously correct.

Reviewed-by: Olivier Fourdan <ofourdan at redhat.com>


More information about the xorg-devel mailing list