Skip to content

Commit 6d3c19f

Browse files
committed
fix NO_VERIFY_OID build in GetOID
1 parent 3351eb4 commit 6d3c19f

1 file changed

Lines changed: 2 additions & 4 deletions

File tree

wolfcrypt/src/asn.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7609,9 +7609,9 @@ static int GetOID(const byte* input, word32* inOutIdx, word32* oid,
76097609
{
76107610
int ret = 0;
76117611
word32 idx = *inOutIdx;
7612-
#ifndef NO_VERIFY_OID
76137612
word32 actualOidSz;
76147613
const byte* actualOid;
7614+
#ifndef NO_VERIFY_OID
76157615
const byte* checkOid = NULL;
76167616
word32 checkOidSz;
76177617
#endif /* NO_VERIFY_OID */
@@ -7623,11 +7623,9 @@ static int GetOID(const byte* input, word32* inOutIdx, word32* oid,
76237623
(void)oidType;
76247624
*oid = 0;
76257625

7626-
#if !defined(NO_VERIFY_OID) || defined(WOLFSSL_FPKI)
7627-
/* Keep references to OID data and length for check. */
7626+
/* Keep references to OID data and length for sum and (optional) check. */
76287627
actualOid = &input[idx];
76297628
actualOidSz = (word32)length;
7630-
#endif /* NO_VERIFY_OID */
76317629

76327630
*oid = wc_oid_sum(actualOid, (int)actualOidSz);
76337631
idx += actualOidSz;

0 commit comments

Comments
 (0)