Fixes #3373: Move r27542 to v1.7 branch (stomp compiler warnings)

---svn-pre-commit-ignore-below---

r27542 [[BR]]
Cleanup warnings that may be messing up older compilers, remove unused variables


cmr:v1.7
Prep for release candidate