[LTP] [PATCH v1] Refactor fork09 using new LTP API

Richard Palethorpe rpalethorpe@suse.de
Thu Nov 2 13:56:33 CET 2023


Hello,

Cyril Hrubis <chrubis@suse.cz> writes:

> Hi!
> Honestly I'm struggling to understand the point of this test, the
> description says:
>
> "Check that child has access to a full set of files"
>
> What is that supposed to mean? I guess that if we wanted to check that
> the child has inherited the file descriptors ee should open a few files,
> do some changes in the child/parent and check that they are not propagated to
> the other one. I.e. reading from a file in child/parent does not change
> file offset in parent. Closing a file descriptor from a child/parent
> does not close the file in the other one, etc.

This is what the fork10 rewrite does unless I am mistaken? So possibly
they can be combined.

fork12's description sugggests it does the same thing, but thhe test
just seems to test forking until a resource limit is hit. This overlaps
other tests and can probably be deleted.

>
> Also why do we use fopen() instead of just open()?
>
> -- 
> Cyril Hrubis
> chrubis@suse.cz


-- 
Thank you,
Richard.


More information about the ltp mailing list