public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
From: Cyril Hrubis <chrubis@suse.cz>
To: chenguanxi11234@163.com
Cc: yang.guang5@zte.com.cn, ltp@lists.linux.it, chen.haonan2@zte.com.cn
Subject: Re: [LTP] [PATCH v3] posix/conformance/interfaces/sem_timedwait/2-1: Fix test
Date: Wed, 28 Aug 2024 15:33:05 +0200	[thread overview]
Message-ID: <Zs8nEXethFkWi-d5@yuki.lan> (raw)
In-Reply-To: <c82e787a5e77e6c7bc7cbac6338f4ce33b1079b2.1722929348.git.chen.haonan2@zte.com.cn>

Hi!
Pushed with a minor change, thanks.

> -		if (!WEXITSTATUS(i)) {
> +		if (WEXITSTATUS(i)) {
>  			return PTS_FAIL;
>  		}

The return value from WEXITSTATUS() is only valid if WIFEXITED() is true
so I've changed this part as:

@@ -71,7 +71,7 @@ int main(void)
                        return PTS_UNRESOLVED;
                }

-               if (WEXITSTATUS(i)) {
+               if (!WIFEXITED(i) || WEXITSTATUS(i)) {
                        return PTS_FAIL;
                }
                puts("TEST PASSED");

-- 
Cyril Hrubis
chrubis@suse.cz

-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

      reply	other threads:[~2024-08-28 13:34 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-08-11 12:33 [LTP] [PATCH v3] posix/conformance/interfaces/sem_timedwait/2-1: Fix test chenguanxi11234
2024-08-28 13:33 ` Cyril Hrubis [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Zs8nEXethFkWi-d5@yuki.lan \
    --to=chrubis@suse.cz \
    --cc=chen.haonan2@zte.com.cn \
    --cc=chenguanxi11234@163.com \
    --cc=ltp@lists.linux.it \
    --cc=yang.guang5@zte.com.cn \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox