crypto: de-init NSS after calling PR_GetError()

PR_Cleanup() can clear out the error, and we don't want to
loose it.
This commit is contained in:
Dan Williams 2010-01-21 12:57:31 -08:00
parent 8720a74c2e
commit 7a594f2bdc

View file

@ -51,11 +51,11 @@ crypto_init (GError **error)
PR_Init(PR_USER_THREAD, PR_PRIORITY_NORMAL, 1);
ret = NSS_NoDB_Init (NULL);
if (ret != SECSuccess) {
PR_Cleanup ();
g_set_error (error, NM_CRYPTO_ERROR,
NM_CRYPTO_ERR_INIT_FAILED,
_("Failed to initialize the crypto engine: %d."),
PR_GetError ());
PR_Cleanup ();
return FALSE;
}