Fixes to errors encountered on a 32 bit system.