fix some warnings: unused variable, may be uninitialized
add .gitignore