]> git.notmuchmail.org Git - notmuch/blobdiff - mime-node.c
cli/crypto: fix segfault on failed gmime2 crypto context creation
[notmuch] / mime-node.c
index bb0870d024ad1f82127e37eeb564578bc9a2695a..1609173576e2fa4830e04540231f008bab48f2c8 100644 (file)
@@ -247,7 +247,7 @@ _mime_node_create (mime_node_t *parent, GMimeObject *part)
        const char *protocol = g_mime_content_type_get_parameter (content_type, "protocol");
        cryptoctx = notmuch_crypto_get_context (node->ctx->crypto, protocol);
        if (!cryptoctx)
        const char *protocol = g_mime_content_type_get_parameter (content_type, "protocol");
        cryptoctx = notmuch_crypto_get_context (node->ctx->crypto, protocol);
        if (!cryptoctx)
-           return NULL;
+           return node;
     }
 #endif
 
     }
 #endif