File: OpenSSL/crypto/crypto.c
Function: crypto_load_crl
Error: returning (PyObject*)NULL without setting an exception
457 static PyObject *
458 crypto_load_crl(PyObject *spam, PyObject *args) {
459     int type, len;
460     char *buffer;
461     BIO *bio;
462     X509_CRL *crl;
463 
464     if (!PyArg_ParseTuple(args, "is#:load_crl", &type, &buffer, &len)) {
when PyArg_ParseTuple() succeeds
taking False path
465         return NULL;
466     }
467 
468     bio = BIO_new_mem_buf(buffer, len);
469     switch (type) {
when following case 1
470         case X509_FILETYPE_PEM:
471             crl = PEM_read_bio_X509_CRL(bio, NULL, NULL, NULL);
472             break;
473 
474         case X509_FILETYPE_ASN1:
475             crl = d2i_X509_CRL_bio(bio, NULL);
476             break;
477 
478         default:
479             PyErr_SetString(PyExc_ValueError, "type argument must be FILETYPE_PEM or FILETYPE_ASN1");
480             BIO_free(bio);
481             return NULL;
482     }
483     BIO_free(bio);
484 
485     if (crl == NULL) {
when treating unknown struct X509_CRL * from OpenSSL/crypto/crypto.c:471 as NULL
taking True path
486         exception_from_error_queue(crypto_Error);
487         return NULL;
488     }
489 
490     return (PyObject *)crypto_CRL_New(crl);
491 }
returning (PyObject*)NULL without setting an exception
found 1 similar trace(s) to this