fix calls of posix function.