On Mon, Jul 04, 2011 at 04:09:16PM +1000, Peter Hutterer wrote:
> +/**
> + * Append pInfo to the null-terminated list, allocating space as necessary.
> + * pInfo is copied into the last element.
> + */
> +static InputInfoPtr*
> +addDevice(InputInfoPtr *list, InputInfoPtr pInfo)
> +{
> + InputInfoPtr *devs;
> + int count = 1;
> +
> + for (devs = list; devs && *devs; devs++)
> + count++;
> +
> + list = xnfrealloc(list, (count + 1) * sizeof(InputInfoPtr));
> + list[count] = NULL;
> +
> + list[count - 1] = xnfalloc(sizeof(InputInfoRec));
> + *list[count - 1] = *pInfo;
Could you not use your new InputInfoRec duplication here?
> + return list;
> +}
With that, for the series:
Reviewed-by: Daniel Stone <[email protected]>
Cheers,
Daniel
_______________________________________________
[email protected]: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel