Fix types for 64-bit compilation