Hopefully improve ReadLoop termination conditions, fixes #64