fixed #303: replace %ld with % PRId64
remove unused variable
Merge pull request #305 from Liuchang0812/fix-logging

remove unused variable
Merge pull request #304 from Liuchang0812/fix-check

fixed #303: replace %ld with % PRId64