Fix OS X crashes.
small additions to .gitignore
Merge pull request #3 from rgngl/osxfix

OS X fixes