Fix VS2010 debug builds. It was caused by my Pangya fix: I had this else statement in the wrong place.
Merge pull request #2005 from thedax/master

Fix VS2010 debug builds