DCOM-108: [GH-184] Fix bug in classExists when using multiple autoloaders (i.e. ZF2) #405

Closed
doctrinebot opened this Issue Sep 17, 2012 · 5 comments

2 participants

@doctrinebot

Jira issue originally created by user @beberlei:

This issue is created automatically through a Github pull request on behalf of bramstroker:

Url: #184

Message:

The autoloading routine in the classExists method makes the assumption the autoload method always returns a value (i.e. no void) when the autoloading of a class is succesfull. When you have multiple autoloaders registered to the spl stack this can lead to problems. In my case I'm using ZF2 ClassmapAutoloader and StandardAutoloader as fallback. The classmapAutoloader returns nothing so the autoload method in the StandardAutoloader is called as well, because the for loop is continued. This results in a second include, and a fatal error "Cannot redeclare class" is triggered.

@doctrinebot

Comment created by @beberlei:

A related Github Pull-Request [GH-184] was closed
#184

@doctrinebot

Comment created by @beberlei:

A related Github Pull-Request [GH-184] was reopened
#184

@doctrinebot

Issue was closed with resolution "Duplicate"

@doctrinebot

Comment created by @ocramius:

Handled in DCOM-136

@doctrinebot

Comment created by @doctrinebot:

A related Github Pull-Request [GH-184] was closed:
doctrine/dbal#184

@doctrinebot doctrinebot added the Bug label Dec 6, 2015
@Ocramius Ocramius was assigned by doctrinebot Dec 6, 2015
@doctrinebot doctrinebot closed this Dec 6, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment