Fix warnings

This fixes some amount of warnings that have accumulated. I would like to remind everyone that we should strive for a warning-free compile! (I use more and/or stricter warning options than most others, so I will see more warnings, though.)