64bit portability fix