Experiment with HLint: some code fixups as suggested by it, and some indentation.
Reindent endpointLoop and minor refactoring to it.

In order to keep line length under control. Most lines now fit under
80 columns. This was obtained without having to break them.
More fixes proposed by HLint.
Shorten 'sendRMA'.
Merge pull request #4 from ps-labs/hlint-indentation

HLint guided code cleanups