Fix all the new warnings triggered by newly turned on warnings.

- See previous commit (1cb847c623e9ce4504895fc78fcb0d980b46a46a) for the
warning flags.

Signed-off-by: Aron Cedercrantz <aron@cedercrantz.se>