]> git.ipfire.org Git - thirdparty/chrony.git/commit
refclock_rtc: fix finalization with closed descriptor
authorMiroslav Lichvar <mlichvar@redhat.com>
Wed, 11 Jun 2025 11:30:57 +0000 (13:30 +0200)
committerMiroslav Lichvar <mlichvar@redhat.com>
Wed, 11 Jun 2025 11:39:17 +0000 (13:39 +0200)
commite463fcab49ddfcc727f35e5bb1f895ab1fb89fa5
treee2c4d76a723408e243a4710f4c9f4e98ec9d2e26
parentdf98fb4fc79d33a788b51cc0762917f42e9a768f
refclock_rtc: fix finalization with closed descriptor

If the RTC file descriptor was closed and removed after a read error,
don't try to close and remove it again in the driver finalization to
avoid an assertion failure on the negative descriptor.

Fixes: 4f22883f4e71 ("refclock: add new refclock for RTCs")
refclock_rtc.c