<div dir="auto"><div><br><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Mar 7, 2019, 3:00 AM Cyril Hrubis <<a href="mailto:chrubis@suse.cz">chrubis@suse.cz</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi!<br>
> - ltpuser = SAFE_GETPWNAM(username);<br>
> - uid = ltpuser->pw_uid;<br>
> + if (!tst_run_cmd(cmd_useradd, NULL, NULL, 1)) {<br>
> + user_added = 1;<br>
> + ltpuser = SAFE_GETPWNAM(username);<br>
> + uid = ltpuser->pw_uid;<br>
> + }<br>
<br>
The only thing that I don't like here is that we do not check the cause<br>
of failure here. What exactly happens on android, is useradd missing<br>
there completely?</blockquote></div></div><div dir="auto"><br></div><div dir="auto"></div><div dir="auto">Correct, useradd is missing.</div><div dir="auto"><br></div><div dir="auto"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"> If so we should proceed with TCONF only if<br>
tst_run_cmd() returned 255 and TBROK the test on other non-zero return<br>
values.<br></blockquote></div></div><div dir="auto"><br></div><div dir="auto">But is the test that's broken if useradd fails for wherever reason? Isn't it a configuration issue?</div><div dir="auto"><br></div><div dir="auto">Thanks,</div><div dir="auto">Saravana</div></div>