Fixes #791 Exceptions in close cause empty JedisPool and then deadlock

This is a fix for https://github.com/xetorthio/jedis/issues/791 which is giving us problems in our production code.

Creating a test for this was a bit interesting without Mockito, but managed to mock the failing behaviour and create a test for the defect, even if it is not the most prettiest of tests out there. :)