Use a proper IO.catch instead of 'try...with' in Mutex.with_mutex

/cc @rdegnan