Rewrite filediffer to C and make it work properly.