fix compile error with g++ 4.8+