scan-build: remove dead assignments

- variables that are set but never read again