[PATCH xserver 4/7] test: Return error from simple-xinit if the client crashes.

Keith Packard keithp at keithp.com
Thu Aug 3 18:59:15 UTC 2017


Eric Anholt <eric at anholt.net> writes:

> I want to be able to call client tests with simple-xinit, so assertion
> failures should be an error.

> +        if (WIFSIGNALED(wstatus))
> +            return 1;
> +
> +        if (WCOREDUMP(wstatus))
> +            return 1;
> +
> +        assert(WIFEXITED(wstatus));
>          return WEXITSTATUS(wstatus);

Could just be

        if (!WIFEXITED(wstatus))
                return 1;
        return WEXITSTATUS(wstatus);

-- 
-keith
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 832 bytes
Desc: not available
URL: <https://lists.x.org/archives/xorg-devel/attachments/20170803/d8d301a4/attachment.sig>


More information about the xorg-devel mailing list