Improve the code ensuring the read go routines all quit in the compare function.
Improve the code ensuring the read go routines all quit in the compare function.

The if statement was ugly from the previous work to quit all go routines.
Since the desired variable already existed, it improved the general logic,
reduce the amount of variables in more global scopes.  Also the if function
is now gone.

MJDSystems/kilium,MJDSystems/kilium