Date: Sat, 20 May 2023 19:30:12 +0000 From: bugzilla-noreply@freebsd.org To: ports-bugs@FreeBSD.org Subject: [Bug 271539] mail/panda-cclient: fix build with clang 16 Message-ID: <bug-271539-7788@https.bugs.freebsd.org/bugzilla/>
next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D271539 Bug ID: 271539 Summary: mail/panda-cclient: fix build with clang 16 Product: Ports & Packages Version: Latest Hardware: Any OS: Any Status: New Severity: Affects Some People Priority: --- Component: Individual Port(s) Assignee: thierry@FreeBSD.org Reporter: dim@FreeBSD.org Assignee: thierry@FreeBSD.org Flags: maintainer-feedback?(thierry@FreeBSD.org) Clang 16 has a new error about incompatible function types, which shows up when building mail/panda-cclient: news.c:370:36: error: incompatible function pointer types passing 'int (struct dirent *)' to parameter of type 'int (*)(const struct dirent *)' [-Wincompatible-function-pointer-types] if ((nmsgs =3D scandir (tmp,&names,news_select,news_numsort)) >=3D 0) { ^~~~~~~~~~~ /usr/include/dirent.h:127:12: note: passing argument to parameter here int (*)(const struct dirent *), int (*)(const struct dirent *= *, ^ news.c:370:48: error: incompatible function pointer types passing 'int (c= onst void *, const void *)' to parameter of type 'int (*)(const struct dirent **, const struct dirent **)' [-Wincompatible-function-pointer-types] if ((nmsgs =3D scandir (tmp,&names,news_select,news_numsort)) >=3D 0) { ^~~~~~~~~~~~ /usr/include/dirent.h:127:44: note: passing argument to parameter here int (*)(const struct dirent *), int (*)(const struct dirent *= *, ^ This is because the prototypes for the scandir(3) 'select' and 'compar' callback function parameters do not match the declarations in <dirent.h>. The same occurs in a few other files under src/osdep/unix. Fix these by using the correct parameter types for the callback functions. --=20 You are receiving this mail because: You are the assignee for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-271539-7788>