Fix gcc46 build