Speed up ExceptionCatch event callback

Return from the callback immediately when there is no uncaught exception
to be checked. I suppose that the majority of ExceptionCatch events
occur in normal state of execution. The current solution needs to get
TID of the current thread just to find out that the uncaught exceptions
map is empty. This is not necessary because the map can provide such
information by counting the stored items. If the size of the map is
zero, we can safely return from the exception callback without other
processing.

Related to rhbz#1051198