Fixing some codes so I can build with GCC 4.7. Google's GCC 4.7 used