-
Type: Bug
-
Resolution: Fixed
-
Priority: Minor - P4
-
Affects Version/s: None
-
Component/s: None
-
None
I think createDecryptionContext, createDataKeyContext, createExplicitEncryptionContext, and createExplicitDecryptionContext throw the wrong exception when mongocrypt_ctx_new fails:
mongocrypt_ctx_t context = mongocrypt_ctx_new(wrapped); if (context == null) { MongoCryptContextImpl.throwExceptionFromStatus(context); }
Should be:
mongocrypt_ctx_t context = mongocrypt_ctx_new(wrapped); if (context == null) { throwExceptionFromStatus(); }