Doctrine 2 - ORM
  1. Doctrine 2 - ORM
  2. DDC-1367

Include path not passed to ClassLoader when autoloading Doctrine library from directory

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Critical Critical
    • Resolution: Fixed
    • Affects Version/s: 2.1, 2.1.1, Git Master
    • Fix Version/s: 2.1.2
    • Component/s: Tools
    • Security Level: All
    • Labels:
      None
    • Environment:
      Found while trying to write a Doctrine 2.1 module for Kohana.

      Description

      The bug is in ORM\Tools\Setup.php in the function registerAutoloadDirectory($directory), specificially the following line:

      $loader = new ClassLoader("Doctrine");

      Which should actually be:

      $loader = new ClassLoader("Doctrine", $directory);

      As it stands the actual directory location is not being passed to the ClassLoader while attempting to autoload the Doctrine from that specified directory. Under certain circumstances this causes loading to completely fail (although in cases where this function is being called from a parent directory to Doctrine this seems to go unnoticed - perhaps why this was not picked up sooner?)

        Activity

        Hide
        Benjamin Eberlei added a comment -

        Fixed and merged into 2.1.x

        Show
        Benjamin Eberlei added a comment - Fixed and merged into 2.1.x

          People

          • Assignee:
            Benjamin Eberlei
            Reporter:
            Lucas Brown
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: