Fix a 64-bit warning. While here, also fix a gcc34 warning.