Make some important preparing fixes.