Uploaded image for project: 'CiviCRM'
  1. CiviCRM
  2. CRM-15764

Make use of opendir() more consistent

    Details

    • Type: Bug
    • Status: Done/Fixed
    • Priority: Trivial
    • Resolution: Fixed/Completed
    • Affects Version/s: 4.5.5
    • Fix Version/s: 4.6
    • Component/s: Core CiviCRM
    • Labels:
      None
    • Documentation Required?:
      None

      Description

      When transferring a site recently, I saw an issue where a while(readdir()) loop didn't exit because the results of opendir() weren't checked; if the directory doesn't exist then readdir() doesn't have a handle to read from.

      Pretty sure this was in CRM_Utils_File::getFilesByExtension(), may be reproducible by removing / relocating the extensions directory (or some other expected directory).

        Attachments

          Activity

            People

            • Assignee:
              rohan1990 Rohan Ramesh Katkar
              Reporter:
              xurizaemon Chris Burgess
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: