Message ID | 20200923084422.13101-1-yangx.jy@cn.fujitsu.com |
---|---|
State | Accepted |
Headers | show |
Series | syscalls/recvmmsg01.c: Fix a compiler error | expand |
> Use correct ts.type to fix the following compiler error: > -------------------------------------------- > recvmmsg01.c:86:9: error: request for member ‘type’ in something not a structure or union > timeout.type = tv->ts_type; > -------------------------------------------- > Fixes: 135af8ededd4 ("syscalls/{send|recv}mmsg: add a test case for timeout and errno test") > Signed-off-by: Xiao Yang <yangx.jy@cn.fujitsu.com> Reviewed-by: Petr Vorel <pvorel@suse.cz> PS: my solution was wrong. Kind regards, Petr > --- > testcases/kernel/syscalls/recvmmsg/recvmmsg01.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > diff --git a/testcases/kernel/syscalls/recvmmsg/recvmmsg01.c b/testcases/kernel/syscalls/recvmmsg/recvmmsg01.c > index fe637430b..d3f2df6d9 100644 > --- a/testcases/kernel/syscalls/recvmmsg/recvmmsg01.c > +++ b/testcases/kernel/syscalls/recvmmsg/recvmmsg01.c > @@ -83,7 +83,7 @@ static void do_test(unsigned int i) > memset(rcv1->iov_base, 0, rcv1->iov_len); > memset(rcv2->iov_base, 0, rcv2->iov_len); > - timeout.type = tv->ts_type; > + ts.type = tv->ts_type; > tst_ts_set_sec(&ts, tc->tv_sec); > tst_ts_set_nsec(&ts, tc->tv_nsec);
BTW: reported by Li Wang and also by P.-H. Lin: https://github.com/linux-test-project/ltp/issues/727 Kind regards, Petr
----- Original Message ----- > Use correct ts.type to fix the following compiler error: > -------------------------------------------- > recvmmsg01.c:86:9: error: request for member ‘type’ in something not a > structure or union > timeout.type = tv->ts_type; > -------------------------------------------- > > Fixes: 135af8ededd4 ("syscalls/{send|recv}mmsg: add a test case for timeout > and errno test") > Signed-off-by: Xiao Yang <yangx.jy@cn.fujitsu.com> Acked-by: Jan Stancek <jstancek@redhat.com>
On 9/23/20 5:51 PM, Petr Vorel wrote: > BTW: reported by Li Wang > > and also by P.-H. Lin: > https://github.com/linux-test-project/ltp/issues/727 Hi Petr and Jan, Sure, I will add Reported-by and the number of issue. Also thanks for your review. :-) Thanks, Xiao Yang > > Kind regards, > Petr >
Hi! Actually I've messed up here, I pushed the patch by an accident, the code is not ready to be included. Let me just revert it.
On 2020/9/25 19:59, Cyril Hrubis wrote: > Hi! > Actually I've messed up here, I pushed the patch by an accident, the > code is not ready to be included. Let me just revert it. Hi Cyril, Thanks for your explanation. :-) It is fine for me to revert it. Best Regards, Xiao Yang
diff --git a/testcases/kernel/syscalls/recvmmsg/recvmmsg01.c b/testcases/kernel/syscalls/recvmmsg/recvmmsg01.c index fe637430b..d3f2df6d9 100644 --- a/testcases/kernel/syscalls/recvmmsg/recvmmsg01.c +++ b/testcases/kernel/syscalls/recvmmsg/recvmmsg01.c @@ -83,7 +83,7 @@ static void do_test(unsigned int i) memset(rcv1->iov_base, 0, rcv1->iov_len); memset(rcv2->iov_base, 0, rcv2->iov_len); - timeout.type = tv->ts_type; + ts.type = tv->ts_type; tst_ts_set_sec(&ts, tc->tv_sec); tst_ts_set_nsec(&ts, tc->tv_nsec);
Use correct ts.type to fix the following compiler error: -------------------------------------------- recvmmsg01.c:86:9: error: request for member ‘type’ in something not a structure or union timeout.type = tv->ts_type; -------------------------------------------- Fixes: 135af8ededd4 ("syscalls/{send|recv}mmsg: add a test case for timeout and errno test") Signed-off-by: Xiao Yang <yangx.jy@cn.fujitsu.com> --- testcases/kernel/syscalls/recvmmsg/recvmmsg01.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)