fix opendir/closedir for 32bit; remove fallocate