From: Theo Buehler Subject: [llvm22] monitoring-plugins: cast for sockaddr_un * To: ports@openbsd.org Cc: stu@spacehopper.org Date: Fri, 22 May 2026 08:11:50 +0200 This fails in a connect call with error: incompatible pointer types passing 'struct sockaddr_un *' to parameter of type 'const struct sockaddr *' [-Wincompatible-pointer-types] so add the missing cast. Index: Makefile =================================================================== RCS file: /cvs/ports/net/monitoring-plugins/Makefile,v diff -u -p -r1.58 Makefile --- Makefile 14 Apr 2026 14:44:22 -0000 1.58 +++ Makefile 22 May 2026 06:00:00 -0000 @@ -14,6 +14,8 @@ GH_ACCOUNT= monitoring-plugins GH_PROJECT= monitoring-plugins GH_TAGNAME= v${V:S/rc/-rc/:S/pl0//} +REVISION= 0 + DISTNAME= monitoring-plugins-${V:S/rc/-rc/} PKGNAME-main= monitoring-plugins-$V PKGNAME-dbi= monitoring-plugins-dbi-$V Index: patches/patch-plugins_check_ntp_time_c =================================================================== RCS file: patches/patch-plugins_check_ntp_time_c diff -N patches/patch-plugins_check_ntp_time_c --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ patches/patch-plugins_check_ntp_time_c 22 May 2026 06:08:46 -0000 @@ -0,0 +1,14 @@ +error: incompatible pointer types passing 'struct sockaddr_un *' to parameter of type 'const struct sockaddr *' [-Wincompatible-pointer-types] + +Index: plugins/check_ntp_time.c +--- plugins/check_ntp_time.c.orig ++++ plugins/check_ntp_time.c +@@ -397,7 +397,7 @@ static offset_request_wrapper offset_request(const cha + + strncpy(unix_socket.sun_path, host, strlen(host)); + +- if (connect(socklist[0], &unix_socket, sizeof(unix_socket))) { ++ if (connect(socklist[0], (const struct sockaddr *)&unix_socket, sizeof(unix_socket))) { + /* don't die here, because it is enough if there is one server + answering in time. This also would break for dual ipv4/6 stacked + ntp servers when the client only supports on of them.