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

llapi_file_get_stripe() fails with ENAMETOOLONG

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Minor
    • Lustre 1.8.7
    • Lustre 1.8.6
    • None
    • 3
    • 22,766
    • 6578

    Description

      The patch from bugzilla ticket 22766 added the following code:

      diff --git a/lustre/utils/liblustreapi.c b/lustre/utils/liblustreapi.c
      index 1e88a51..72818c8 100644
      --- a/lustre/utils/liblustreapi.c
      +++ b/lustre/utils/liblustreapi.c
      @@ -1566,6 +1566,8 @@ int llapi_file_get_stripe(const char *path, struct lov_user_md *lum)
               int fd, rc = 0;
       
               fname = strrchr(path, '/');
      +        if (strlen(fname) + 1 < sizeof(struct lov_user_md))
      +                return ENAMETOOLONG;
      

      This check does not make any sense and causes llapi_file_get_stripe() to fail with ENAMETOOLONG without any obvious reasons.

      Attachments

        Issue Links

          Activity

            People

              johann Johann Lombardi (Inactive)
              johann Johann Lombardi (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: