[Git][NTPsec/ntpsec][master] Fix #842: packetstamp crash on SCM_TIMESTAMPNS_OLD

Hal Murray (@hal.murray) gitlab at mg.gitlab.com
Sun Apr 6 19:58:17 UTC 2025



Hal Murray pushed to branch master at NTPsec / ntpsec


Commits:
16cfa812 by Hal Murray at 2025-04-06T12:55:40-07:00
Fix #842: packetstamp crash on SCM_TIMESTAMPNS_OLD

- - - - -


1 changed file:

- ntpd/ntp_packetstamp.c


Changes:

=====================================
ntpd/ntp_packetstamp.c
=====================================
@@ -337,7 +337,12 @@ fetch_packetstamp(
 	}
 #if defined(SO_TIMESTAMPNS)
 	/* Linux and ?? */
-	if (SCM_TIMESTAMPNS != cmsghdr->cmsg_type) {
+	if ((SCM_TIMESTAMPNS != cmsghdr->cmsg_type)
+#ifdef SCM_TIMESTAMPNS_OLD
+	    /* Ubuntu 20.04.2 on ZeroPi??, see #842 */
+            && (SCM_TIMESTAMPNS_OLD != cmsghdr->cmsg_type)
+#endif
+          ) {
 #elif defined(SO_TS_CLOCK)
 	/* FreeBSD */
 	if (SCM_REALTIME != cmsghdr->cmsg_type) {



View it on GitLab: https://gitlab.com/NTPsec/ntpsec/-/commit/16cfa812e790c2786ea130a300452d9e587eaf18

-- 
View it on GitLab: https://gitlab.com/NTPsec/ntpsec/-/commit/16cfa812e790c2786ea130a300452d9e587eaf18
You're receiving this email because of your account on gitlab.com.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ntpsec.org/pipermail/vc/attachments/20250406/76c0d1dc/attachment.htm>


More information about the vc mailing list