fix build errors using gcc-4.10