Fixed warnings

Hey @decastrol - I fixed the warnings with Incompatible pointer types and crash from Key value coding-compliance issue. Feel free to "merge this pull request" from my Fork of your project, or simply make the changes in your own local copy of this code.