2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 <2020> 2021 2022 2023 2024 2025 | Index | 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 <2020> 2021 2022 2023 2024 2025 |
<== Date ==> | <== Thread ==> |
---|
Subject: | Re: AW: AW: AW: Problems with hanging osiSockTest |
From: | Ralph Lange via Core-talk <core-talk at aps.anl.gov> |
To: | EPICS Core Talk <core-talk at aps.anl.gov> |
Date: | Fri, 20 Nov 2020 17:13:36 +0100 |
On 11/20/20 12:49 AM, Zimoch Dirk (PSI) wrote:
> Which this change, the tests terminates and succeeds.
>
> Please do not have variable declarations after instructions in C (non C++) code. Not all compilers like that. I already had to fix udpSockFanoutTestRx() because of this problem:
How could we expand our CI coverage to discover this?
Do your CI builds cover this case? (a non-MS compiler
which still imposes this C89 ordering restriction by
default)
> @@ -213,6 +213,7 @@ void udpSockFanoutTestRx(void* raw)
> {
> struct TInfo *info = raw;
> epicsTimeStamp start, now;
> + unsigned nremain = nrepeat;
> #ifdef _WIN32
> /* ms */
> DWORD timeout = 10000;
> @@ -222,7 +223,6 @@ void udpSockFanoutTestRx(void* raw)
> timeout.tv_sec = 10;
> timeout.tv_usec = 0;
> #endif
> - unsigned nremain = nrepeat;
>
> (void)epicsTimeGetCurrent(&start);
> now = start;
>
>
>
> Dirk
>
>> -----Ursprüngliche Nachricht-----
>> Von: Michael Davidsaver <mdavidsaver at gmail.com>
>> Gesendet: Donnerstag, 19. November 2020 19:24
>> An: Zimoch Dirk (PSI) <dirk.zimoch at psi.ch>
>> Cc: Johnson, Andrew N. <anj at anl.gov>; EPICS core-talk <core-
>> talk at aps.anl.gov>
>> Betreff: Re: AW: AW: Problems with hanging osiSockTest
>>
>> On 11/19/20 2:27 AM, Zimoch Dirk (PSI) wrote:
>>> I have tested the latest 7.0 commit.
>>>
>>> osiSockTest still hangs on the virbr0 interface:
>>
>>
>> Ha. I see why my attempt to have this test timeout is broken.
>>
>>
>>> diff --git a/modules/libcom/test/osiSockTest.c
>> b/modules/libcom/test/osiSockTest.c
>>> index e71eec5fe..a3b831b66 100644
>>> --- a/modules/libcom/test/osiSockTest.c
>>> +++ b/modules/libcom/test/osiSockTest.c
>>> @@ -239,6 +239,8 @@ void udpSockFanoutTestRx(void* raw)
>>> osiSockAddr src;
>>> osiSocklen_t srclen = sizeof(src);
>>>
>>> + (void)epicsTimeGetCurrent(&now);
>>> +
>>> int n = recvfrom(info->sock, buf.bytes, sizeof(buf.bytes), 0, &src.sa,
>> &srclen);
>>> buf.bytes[sizeof(buf.bytes)-1] = '\0';
>>>