Clean up some prototypes
Merge pull request #3936 from yebblies/cleanup2

[cleanup] Clean up some prototypes and dead code