Cleanup dead assignments reported by scan-build