<div dir="ltr"><div dir="ltr"><div class="gmail_default" style="font-size:small"><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Dec 16, 2021 at 5:56 PM Martin Doucha <<a href="mailto:mdoucha@suse.cz">mdoucha@suse.cz</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi,<br>
<br>
On 16. 12. 21 4:41, Li Wang wrote:<br>
> diff --git a/lib/tst_test.c b/lib/tst_test.c<br>
> index ce2b8239d..f3ae48240 100644<br>
> --- a/lib/tst_test.c<br>
> +++ b/lib/tst_test.c<br>
> @@ -1441,11 +1441,15 @@ static int fork_testrun(void)<br>
> <br>
> SAFE_SIGNAL(SIGINT, sigint_handler);<br>
> <br>
> + tst_enable_oom_protection(getppid());<br>
<br>
this is exactly what you should *NOT* do because then the OOM protection<br>
will also be inherited by all non-LTP processes executed by the same<br>
shell (or whatever the parent process is).<br></blockquote><div><br></div><div><div class="gmail_default" style="font-size:small">You are right! I previously thought the parent process is only ltp-pan</div><div class="gmail_default" style="font-size:small">and we only need to cancel the protection in fork_testrun's children.</div><div class="gmail_default" style="font-size:small">But obviously, one thing I neglected is that some shell tests will still</div><div class="gmail_default" style="font-size:small">under the affected. And furthermore if run LTP test manually the parent</div><div class="gmail_default" style="font-size:small">will be the shell, non-LTP process also inherits the score.</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">Thanks for pointing out this, I will remove this line in V2.</div></div></div><div><br></div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div>Regards,<br></div><div>Li Wang<br></div></div></div></div>