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

Call raise_memory_limit() with "@" to supress possible warnings

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Won't Fix
    • 1.9.6
    • None
    • Backup
    • None
    • MOODLE_19_STABLE

    Description

      To prevent warnings such as "ini_set() has been disabled for security reasons", we should set memory_limit by "@" call to prevent error displaying.

      We can either put @ in the function itself to call @ini_set() - (my -1 against as it is one way ticket)
      or to call @raise_memory_limit() - this is usually true except two calls from backup: see #2 and #3 in the following list:

      Cscope tag: raise_memory_limit

      1. line file
        1 73 admin/uploadpicture.php <<get_data>>
        @raise_memory_limit("192M");
        2 689 backup/lib.php <<array>>
        raise_memory_limit("192M");
        3 143 backup/restore.php <<basename>>
        raise_memory_limit("192M");
        4 98 grade/import/csv/index.php <<get_data>>
        @raise_memory_limit("192M");
        5 207 grade/import/csv/index.php <<get_data>>
        @raise_memory_limit("192M");
        6 57 grade/import/xml/index.php <<get_data>>
        @raise_memory_limit("256M");
        7 90 mod/data/import.php <<confirm_sesskey>>
        @raise_memory_limit("96M");

      Attachments

        Issue Links

          Activity

            People

              skodak Petr Skoda
              mudrd8mz David Mudrák (@mudrd8mz)
              Nobody Nobody
              Adrian Greeve, David Woloszyn, Huong Nguyen, Jake Dallimore, Michael Hawkins, Stevani Andolo
              Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: