Merge "Fixed crash and 64-bit porting issues"