Fixed ftruncate compile warning on gcc-4.6