Uploaded image for project: 'ZABBIX BUGS AND ISSUES'
  1. ZABBIX BUGS AND ISSUES
  2. ZBX-21946

Implicit declaration of sscanf in configure.ac

XMLWordPrintable

    • Icon: Problem report Problem report
    • Resolution: Unresolved
    • Icon: Major Major
    • None
    • 4.0.44, 5.0.29, 6.0.10, 6.2.4, 6.4.0beta3
    • Packages (C)
    • None

      The HAVE_LONG_LONG_QU check calls sscanf, but does not ensure the function is called. This causes the test to fail with strict C99 compilers even if the format specifier is supported. Something like this should fix it:

      diff --git a/configure.ac b/configure.ac
      index 1a13a5d0365..7c7c24fc952 100644
      --- a/configure.ac
      +++ b/configure.ac
      @@ -952,6 +952,7 @@ dnl FreeBSD 4.x does not support %llu
       AC_MSG_CHECKING(for long long format)
       AC_RUN_IFELSE([AC_LANG_SOURCE([[
       #include <sys/types.h>
      +#include <stdio.h>
       int main()
       {
               uint64_t i;
      

            zabbix.dev Zabbix Development Team
            fweimer Florian Weimer
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: