Don't pass NULL to PR_Lock() during camel_shutdown().
authorMatthew Barnes <mbarnes@redhat.com>
Sat, 24 Oct 2009 23:17:04 +0000 (19:17 -0400)
committerMatthew Barnes <mbarnes@redhat.com>
Mon, 26 Oct 2009 23:08:58 +0000 (19:08 -0400)
camel/camel.c

index 7f999ff..0986d80 100644 (file)
@@ -162,10 +162,12 @@ camel_shutdown (void)
        /* These next calls must come last. */
 
 #if defined (HAVE_NSS)
-       PR_Lock(nss_initlock);
-       if (nss_initialized)
-               NSS_Shutdown ();
-       PR_Unlock(nss_initlock);
+       if (nss_initlock != NULL) {
+               PR_Lock(nss_initlock);
+               if (nss_initialized)
+                       NSS_Shutdown ();
+               PR_Unlock(nss_initlock);
+       }
 #endif /* HAVE_NSS */
 
        initialised = FALSE;