]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
configure: Fix type of argument to backtrace_symbols
authorFlorian Weimer <fweimer@redhat.com>
Tue, 19 Dec 2023 06:56:42 +0000 (07:56 +0100)
committerAlan DeKok <aland@freeradius.org>
Tue, 19 Dec 2023 13:29:16 +0000 (08:29 -0500)
The backtrace_symbols function expects a pointer to an array of
void * values, not a pointer to an array of a single element.
Removing the address operator ensures that the right type is used.

This avoids an unconditional failure of this probe with compilers
that treat incompatible pointer types as a compilation error.

configure
configure.ac

index e30360edf25d50f48584009df66185912b55aa49..f9064dd52bb8244af44e2095e3398a80375cf1b3 100755 (executable)
--- a/configure
+++ b/configure
@@ -14418,7 +14418,7 @@ main (void)
 {
 
       void *sym[1];
-      backtrace_symbols(&sym, sizeof(sym))
+      backtrace_symbols(sym, sizeof(sym))
   ;
   return 0;
 }
index 7d75c5cc3c14bef3f539f2217ec090ee07f5f30f..14287b5e513745c9205bff96ad43dd30711851f3 100644 (file)
@@ -2163,7 +2163,7 @@ if test "x$ac_cv_header_execinfo_h" = "xyes"; then
       #include <execinfo.h>
     ]], [[
       void *sym[1];
-      backtrace_symbols(&sym, sizeof(sym)) ]])],[
+      backtrace_symbols(sym, sizeof(sym)) ]])],[
       AC_MSG_RESULT(yes)
       ac_cv_lib_execinfo_backtrace_symbols="yes"
     ],[