From: Todd C. Miller Date: Sun, 11 Mar 2018 03:16:20 +0000 (-0700) Subject: fix compilation on Solaris X-Git-Tag: SUDO_1_8_23^2~77 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=910f2889486e819fbffebe2a270492936cd28dd7;p=sudo fix compilation on Solaris --- diff --git a/plugins/sudoers/cvtsudoers_ldif.c b/plugins/sudoers/cvtsudoers_ldif.c index 70488a797..3209a03e7 100644 --- a/plugins/sudoers/cvtsudoers_ldif.c +++ b/plugins/sudoers/cvtsudoers_ldif.c @@ -847,7 +847,7 @@ role_to_sudoers(struct sudo_role *role, bool store_options, /* Add source role as a comment. */ if (role->cn != NULL) { - struct comment *comment = NULL; + struct sudoers_comment *comment = NULL; if (reuse_userspec) { /* Try to re-use comment too. */ STAILQ_FOREACH(comment, &us->comments, entries) { diff --git a/plugins/sudoers/fmtsudoers.c b/plugins/sudoers/fmtsudoers.c index 4ab7fb0b4..8d86b3140 100644 --- a/plugins/sudoers/fmtsudoers.c +++ b/plugins/sudoers/fmtsudoers.c @@ -256,7 +256,7 @@ sudoers_format_userspec(struct sudo_lbuf *lbuf, struct userspec *us, bool expand_aliases) { struct privilege *priv; - struct comment *comment; + struct sudoers_comment *comment; struct member *m; debug_decl(sudoers_format_userspec, SUDOERS_DEBUG_UTIL) diff --git a/plugins/sudoers/gram.c b/plugins/sudoers/gram.c index 02f95300f..2a7ddf234 100644 --- a/plugins/sudoers/gram.c +++ b/plugins/sudoers/gram.c @@ -930,7 +930,7 @@ void free_userspec(struct userspec *us) { struct privilege *priv; - struct comment *comment; + struct sudoers_comment *comment; free_members(&us->users); while ((priv = TAILQ_FIRST(&us->privileges)) != NULL) { diff --git a/plugins/sudoers/gram.y b/plugins/sudoers/gram.y index cc54e1013..1f36c5057 100644 --- a/plugins/sudoers/gram.y +++ b/plugins/sudoers/gram.y @@ -1158,7 +1158,7 @@ void free_userspec(struct userspec *us) { struct privilege *priv; - struct comment *comment; + struct sudoers_comment *comment; free_members(&us->users); while ((priv = TAILQ_FIRST(&us->privileges)) != NULL) { diff --git a/plugins/sudoers/parse.h b/plugins/sudoers/parse.h index dd5ac9ef1..85c9e750b 100644 --- a/plugins/sudoers/parse.h +++ b/plugins/sudoers/parse.h @@ -150,7 +150,7 @@ TAILQ_HEAD(userspec_list, userspec); TAILQ_HEAD(member_list, member); TAILQ_HEAD(privilege_list, privilege); TAILQ_HEAD(cmndspec_list, cmndspec); -STAILQ_HEAD(comment_list, comment); +STAILQ_HEAD(comment_list, sudoers_comment); /* * Structure describing a user specification and list thereof. @@ -211,8 +211,8 @@ struct runascontainer { struct member *runasgroups; }; -struct comment { - STAILQ_ENTRY(comment) entries; +struct sudoers_comment { + STAILQ_ENTRY(sudoers_comment) entries; char *str; };