Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8227737

avoid implicit-function-declaration on AIX

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: 14
    • Fix Version/s: 14
    • Component/s: client-libs
    • Labels:
      None
    • Resolved In Build:
      b07
    • CPU:
      ppc
    • OS:
      aix

      Description

      At various places in the native C coding in jdk, we miss header inclusions on AIX.
      This leads to warnings like :

      /nightly/jdk/src/java.base/unix/native/libjava/childproc.c:99:5: warning: implicitly declaring library function 'snprintf'
      with type 'int (char *, unsigned long, const char *, ...)' [-Wimplicit-function-declaration]
          snprintf(aix_fd_dir, 32, "/proc/%d/fd", getpid());
          ^
      /nightly/jdk/src/java.base/unix/native/libjava/childproc.c:99:5: note: include the header <stdio.h> or explicitly provide a declaration for 'snprintf'

      or

      /nightly/jdk/src/java.base/aix/native/libjli/java_md_aix.c:38:5: warning: implicitly declaring library function 'memset'
      with type 'void *(void *, int, unsigned long)' [-Wimplicit-function-declaration]
          memset((void *)info, 0, sizeof(Dl_info));

      /nightly/jdk/src/java.base/aix/native/libjli/java_md_aix.c:38:5: note: include the header <string.h> or explicitly provide a declaration for 'memset'

        Attachments

          Activity

            People

            Assignee:
            mbaesken Matthias Baesken
            Reporter:
            mbaesken Matthias Baesken
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: