[LTP] [PATCH 1/1] recvmmsg01: Workaround segfault on libc variant on 32 bit
Petr Vorel
pvorel@suse.cz
Mon Nov 25 22:32:41 CET 2024
...
> > +static void test_bad_addr(unsigned int i)
> > +{
> > + struct time64_variants *tv = &variants[tst_variant];
> > + void *timeout = bad_addr;
> > + pid_t pid;
> > + int status;
> > +
> > + pid = SAFE_FORK();
> > + if (!pid) {
> > + verify_recvmmsg(i, timeout);
> > + _exit(!TST_PASS);
> This should be just exit(0). The child should either crash or exit with
> 0 any other result should be considered a bug.
Hm, I changed before merge it to _exit(0), instead of exit(0). As Jan explained
[1] _exit() is just for signal handlers and exit() will also flush open streams.
I guess I should fix it.
Kind regards,
Petr
[1] https://lore.kernel.org/ltp/CAASaF6yDG9VfWOzaSbzEMSGq5LXrqkNfLF7UmMcdWNvqmYywtA@mail.gmail.com/
More information about the ltp
mailing list