Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-65686

Bad call to send_file_not_found in lib/filelib.php

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 3.6, 3.7, 3.8
    • Fix Version/s: 3.6.5, 3.7.1
    • Component/s: Files API
    • Labels:

      Description

      There's an instance of send_file_not_found without its () after it - as I write, this is line 4240 in master. (Line 4221 in 36_STABLE)

      I haven't seen the code get to it - but if it did, it would throw a warning (constant not defined, in some future version this will be an Error) and then promptly do nothing as it'll evaluate to an expression that will do nothing, and pass through to the next thing which is probably not desirable.

      Easy fix, just needs to be changed from send_file_not_found to send_file_not_found().

      If I get time I'll throw a patch together.

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                1 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  8/Jul/19

                  Time Tracking

                  Estimated:
                  Original Estimate - 0 minutes
                  0m
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 10 minutes
                  10m