fix XCALLOC() against GCC 14 -Wcalloc-transposed-args
@@ -268,7 +268,7 @@ static int s_der_decode_sequence_flexi(const unsigned char *in, unsigned long *i
}
l->size = len;
- if ((l->data = XCALLOC(sizeof(wchar_t), l->size)) == NULL) {
+ if ((l->data = XCALLOC(l->size, sizeof(wchar_t))) == NULL) {
err = CRYPT_MEM;
goto error;
@@ -77,7 +77,7 @@ static int s_der_decode_sequence_va(const unsigned char *in, unsigned long inlen
return CRYPT_NOP;
- list = XCALLOC(sizeof(*list), x);
+ list = XCALLOC(x, sizeof(*list));
if (list == NULL) {
return CRYPT_MEM;
@@ -80,7 +80,7 @@ int der_encode_sequence_multi(unsigned char *out, unsigned long *outlen, ...)