Drop use of hstrerror() in favour of gai_strerror()

XMLWordPrintable

    • Type: Problem report
    • Resolution: Unresolved
    • Priority: Trivial
    • None
    • Affects Version/s: 6.4.0alpha1
    • Component/s: Agent (G), Proxy (P), Server (S)
    • None
    • Environment:
      AIX 7.1, Linux

      When compiling the zbxcomms library on AIX, we noticed that hstrerror() was being detected during configure's feature tests, but the compiler raises a warning when compiling the comms.c module, as it fails to see the prototype for the function, which is behind a feature guard macro (_USE_IRS) on AIX, which we don't define.

      Linux marks gethostby*(3) and hstrerror(3) to be obsolete, and advises switching to getaddr*(3) and gai_strerror(3) instead.

      We already use the getaddr*(3) family and the use of hstrerror(3) seems to be an artefact, so I suggest we just make the leap and switch.

            Assignee:
            Zabbix Development Team
            Reporter:
            Juris Lambda (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: