From 21a2ff214bad18be078780b7b46978d644bbc58b Mon Sep 17 00:00:00 2001 From: Jeremy Harris Date: Wed, 21 Aug 2024 11:03:25 +0100 Subject: [PATCH] Add standard wrapper macro for strchrnul() --- src/src/mytypes.h | 2 +- src/src/pdkim/pdkim.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/src/mytypes.h b/src/src/mytypes.h index cac4ee3c9..598569d00 100644 --- a/src/src/mytypes.h +++ b/src/src/mytypes.h @@ -117,7 +117,7 @@ functions that are called quite often; for other calls to external libraries #define Urename(s,t) rename(CCS(s),CCS(t)) #define Ustat(s,t) stat(CCS(s),t) #define Ustrchr(s,n) US strchr(CCS(s),n) -#define CUstrchr(s,n) CUS strchr(CCS(s),n) +#define Ustrchrnul(s,n) US strchrnul(CCS(s),n) #define CUstrerror(n) CUS strerror(n) #define Ustrcmp(s,t) strcmp(CCS(s),CCS(t)) #define Ustrcpy_nt(s,t) strcpy(CS s, CCS t) /* no taint check */ diff --git a/src/src/pdkim/pdkim.c b/src/src/pdkim/pdkim.c index b2caa81ab..13820dc33 100644 --- a/src/src/pdkim/pdkim.c +++ b/src/src/pdkim/pdkim.c @@ -665,7 +665,7 @@ memset(pub, 0, sizeof(pdkim_pubkey)); for (const uschar * ele = raw_record, * tspec, * end, * val; *ele; ele = end) { Uskip_whitespace(&ele); - end = US strchrnul(CS ele, ';'); + end = Ustrchrnul(ele, ';'); tspec = string_copyn(ele, end - ele); if (*end) end++; /* skip the ; */ -- 2.30.2