defWrite.c: defHNsprintfPrefix() constify implementation

This commit is contained in:
Darryl L. Miles 2025-01-04 08:57:32 +00:00 committed by Tim Edwards
parent 4930e0307a
commit 05a5b169bc
1 changed files with 8 additions and 9 deletions

View File

@ -395,14 +395,13 @@ defnodeCount(
void void
defHNsprintf( defHNsprintf(
char *str, char *str,
HierName *hierName, const HierName *hierName,
char divchar) char divchar)
{ {
bool trimGlob, trimLocal; const char *cp;
char *s, *cp, c; char c;
char *defHNsprintfPrefix(); char *defHNsprintfPrefix();
s = str;
if (hierName->hn_parent) str = defHNsprintfPrefix(hierName->hn_parent, str, if (hierName->hn_parent) str = defHNsprintfPrefix(hierName->hn_parent, str,
divchar); divchar);
@ -434,12 +433,12 @@ defHNsprintf(
*str++ = '\0'; *str++ = '\0';
} }
char *defHNsprintfPrefix(hierName, str, divchar) char *defHNsprintfPrefix(
HierName *hierName; const HierName *hierName,
char *str; char *str,
char divchar; char divchar)
{ {
char *cp, c; const char *cp;
if (hierName->hn_parent) if (hierName->hn_parent)
str = defHNsprintfPrefix(hierName->hn_parent, str, divchar); str = defHNsprintfPrefix(hierName->hn_parent, str, divchar);