Hi!
> +static void cleanup(void)
> +{
> + if (futex != NULL)
> + free(futex);
free(NULL) is no-op, there is no reason to check for NULL before passing
a pointer to free().
The rest of the changes looks good to me.
--
Cyril Hrubis
chrubis@suse.cz