Pretty format files and remove unnecessary spaces.

Formatting done according to the "allman" style using
astyle -t4 -xd -f --style=allman *.cc