Home | History | Annotate | Download | only in asn1

Lines Matching refs:pval

72 static int bn_new(ASN1_VALUE **pval, const ASN1_ITEM *it);
73 static void bn_free(ASN1_VALUE **pval, const ASN1_ITEM *it);
75 static int bn_i2c(ASN1_VALUE **pval, unsigned char *cont, int *putype, const ASN1_ITEM *it);
76 static int bn_c2i(ASN1_VALUE **pval, const unsigned char *cont, int len, int utype, char *free_cont, const ASN1_ITEM *it);
95 static int bn_new(ASN1_VALUE **pval, const ASN1_ITEM *it)
97 *pval = (ASN1_VALUE *)BN_new();
98 if(*pval) return 1;
102 static void bn_free(ASN1_VALUE **pval, const ASN1_ITEM *it)
104 if(!*pval) return;
105 if(it->size & BN_SENSITIVE) BN_clear_free((BIGNUM *)*pval);
106 else BN_free((BIGNUM *)*pval);
107 *pval = NULL;
110 static int bn_i2c(ASN1_VALUE **pval, unsigned char *cont, int *putype, const ASN1_ITEM *it)
114 if(!*pval) return -1;
115 bn = (BIGNUM *)*pval;
126 static int bn_c2i(ASN1_VALUE **pval, const unsigned char *cont, int len,
130 if(!*pval) bn_new(pval, it);
131 bn = (BIGNUM *)*pval;
133 bn_free(pval, it);