[ntp:bugs] [Bug 3593] ntpd discards silently (even with debug set) nmea messages after the 5th string

bugzilla-daemon at ntp.org bugzilla-daemon at ntp.org
Thu Jun 13 05:56:09 UTC 2019


http://bugs.ntp.org/show_bug.cgi?id=3593

Juergen Perlinger <perlinger at ntp.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |CONFIRMED
                 CC|                            |perlinger at ntp.org
         AssignedTo|rc-nmea at ntp.org             |perlinger at ntp.org
     Ever Confirmed|0                           |1

--- Comment #2 from Juergen Perlinger <perlinger at ntp.org> 2019-06-13 05:56:09 UTC ---
Philippe, I cannot reproduce the bug, but I can see where and when it happens.

There's a preprocessor conditional around the code that should refill the
buffer queue for unused buffers in 'get_full_recv_buffers()' (#ifdef
HAVE_SIGNALED_IO, around line 229)

IMHO that's the source of the bug -- can you drop the ifdef/endif pair (but NOT
the code inside!) and tell me if that solves the problem?

--------------------------------------------------
side remark:

Plainly spoken, the buffer handling is a bit of a mess. It started as a queue
to handle signal driven IO, then threading became an issue (Windows port), and
you can have a blocking queue signal safe in the absence of threads, or
thread-safe in the absence of signals, but not both.

And an absolutely lock-free queue that has a safe deque/pop operation (and that
includes avoiding even some forms of try/retry loops) is painful to implement
because it needs C11 atomics to be reliable, and we cannot even rely on full
C99 compliance on some targets.

-- 
Configure bugmail: http://bugs.ntp.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


More information about the bugs-announce mailing list