Don't crash if exception class cannot be instantiated

Previously, if one would ^C while the tests were running, a segfault
occurred. While this is typically not something fatal in a production
environment, it's still rather annoying.

Change-Id: I904560782c52c75fa8152e387c22b611e2538074
Reviewed-on: http://review.couchbase.org/26353
Reviewed-by: Matt Ingenthron <matt@couchbase.com>
Tested-by: Matt Ingenthron <matt@couchbase.com>