The mainQueueReachability method returns a singleton

This avoids unnecessary cleaning in dealloc.

Also a small fix to silence the static analyzer warnings.