Bug 5094 - Code cleanup, patch by Zack Middleton and DevHC. Fixes unused-but-set gcc warnings
Added also specific Smokin'Guns code cleanup

(cherry picked from commit 23f6fd1633465c2f750f7b1c490e18b0cffa2cd8)