Fix some source code, also strip trailing whitespace.