Uploaded image for project: 'Lustre'
  1. Lustre
  2. LU-239

Lustre Header (include/lprocfs_status.h) is not ISO C99 complaint

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Minor
    • Lustre 2.1.0
    • Lustre 2.0.0
    • None
    • ISO C99
    • 3
    • 23,787
    • 5047

    Description

      Lustre Header (include/lprocfs_status.h) is not ISO C99 complaint. In particular, there is a small section in lustre/include/lprocfs_status.h that fails to compile with PGI. This involves the use of a GCC extension in lprocfs_status.h for flexible arrays:

      161 struct lprocfs_percpu

      { 162 struct lprocfs_counter lp_cntr[0]; 163 }

      ;

      In this particular case, the nature of the extension is that the flexible array is the sole member
      of the structure. So, one way to fix this is to make the structure ISO C99 compliant:

      161 struct lprocfs_percpu

      { 162 int lp_pad; 163 struct lprocfs_counter lp_cntr[0]; 164 }

      ;

      Attachments

        Activity

          People

            laisiyao Lai Siyao
            laisiyao Lai Siyao
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: