fix unittest on gcc