Add some sanity methods to allow blocking methods to check that they're not being called on the libevent thread.