fixed type issue with gcc