Fixed the compile issues against php 5.3