Skip to content

Commit eb807b8

Browse files
committed
Don't use written parameter of macro directly
Signed-off-by: Steffen Jaeckel <s@jaeckel.eu>
1 parent 2d64fc4 commit eb807b8

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/headers/tomcrypt_pk.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -723,9 +723,10 @@ typedef struct ltc_asn1_list_ {
723723
#define LTC_SET_ASN1_CUSTOM_PRIMITIVE(list, index, Class, Tag, Type, Data, Size) \
724724
do { \
725725
int LTC_TMPVAR(SACP) = (index); \
726+
ltc_asn1_list *LTC_TMPVAR(SACP_list) = (list); \
726727
LTC_SET_ASN1(list, LTC_TMPVAR(SACP), LTC_ASN1_CUSTOM_TYPE, Data, Size); \
727728
LTC_SET_ASN1_IDENTIFIER(list, LTC_TMPVAR(SACP), Class, LTC_ASN1_PC_PRIMITIVE, Tag); \
728-
list[LTC_TMPVAR(SACP)].used = (int)(Type); \
729+
LTC_TMPVAR(SACP_list)[LTC_TMPVAR(SACP)].used = (int)(Type); \
729730
} while (0)
730731

731732
extern const char* der_asn1_class_to_string_map[];

0 commit comments

Comments
 (0)