Remove trailing whitespace in some files
Fix some issues in the unit tests with libeio shutdown