From 2d89b4c27c7393498102e4b9156e3c31a9527c7c Mon Sep 17 00:00:00 2001 From: Jeffrey Altman Date: Mon, 3 Jun 2024 22:26:22 -0400 Subject: [PATCH] kdc: -Wcalloc-transposed args warning: 'calloc' sizes specified with 'sizeof' in the earlier argument and not in the later argument [-Wcalloc-transposed-args]. Swap the args. --- kdc/process.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kdc/process.c b/kdc/process.c index 8f1eb5377..162eb24e2 100644 --- a/kdc/process.c +++ b/kdc/process.c @@ -383,7 +383,7 @@ process_request(krb5_context context, unsigned int i; int claim = 0; - r = calloc(sizeof(*r), 1); + r = calloc(1, sizeof(*r)); if (!r) return krb5_enomem(context); @@ -459,7 +459,7 @@ krb5_kdc_process_request(krb5_context context, return process_request(context, config, 0, buf, len, reply, prependlength, from, addr, datagram_reply); } - + /* * handle the request in `buf, len', from `addr' (or `from' as a string), * sending a reply in `reply'.