Clean certain files of trailing whitespace

I'm only going for the low-hanging fruit here, ie the files
with the fewest lines in need of attention. The more heavily
affected files deserve separate commits.

In socks.c a 'no newline at end of file' was also fixed.