Fix inadvertent masking of errors when detecting jmx agent

The old code was catching *all* exceptions thrown by the code that detects whether
the jmx agent is already running in the VM, including errors that were intended
to be propagated to the caller.