summaryrefslogtreecommitdiffstats
path: root/contrib/ntp/sntp/libopts/genshell.c
diff options
context:
space:
mode:
authorcy <cy@FreeBSD.org>2015-07-05 15:42:16 +0000
committercy <cy@FreeBSD.org>2015-07-05 15:42:16 +0000
commit4798ffa9e1d37998fdd0d94d9c2ad9cb3fb5d110 (patch)
treefb96356e3ef85aaa8d1f5939a9decd315a7ca596 /contrib/ntp/sntp/libopts/genshell.c
parent8920bf0c56d10d9413aa5f7595886836b12c974f (diff)
parent5ef283fde5be3bb35376b46b0d8cdc0e6dff0ad4 (diff)
downloadFreeBSD-src-4798ffa9e1d37998fdd0d94d9c2ad9cb3fb5d110.zip
FreeBSD-src-4798ffa9e1d37998fdd0d94d9c2ad9cb3fb5d110.tar.gz
MFV ntp-4.2.8p3 (r284990).
Approved by: roberto, delphij Security: VuXML: 0d0f3050-1f69-11e5-9ba9-d050996490d0 Security: http://bugs.ntp.org/show_bug.cgi?id=2853 Security: https://www.kb.cert.org/vuls/id/668167 Security: http://support.ntp.org/bin/view/Main/SecurityNotice#June_2015_NTP_Security_Vulnerabi
Diffstat (limited to 'contrib/ntp/sntp/libopts/genshell.c')
-rw-r--r--contrib/ntp/sntp/libopts/genshell.c46
1 files changed, 23 insertions, 23 deletions
diff --git a/contrib/ntp/sntp/libopts/genshell.c b/contrib/ntp/sntp/libopts/genshell.c
index 20e6c15..0f05b3e 100644
--- a/contrib/ntp/sntp/libopts/genshell.c
+++ b/contrib/ntp/sntp/libopts/genshell.c
@@ -294,7 +294,7 @@ doUsageOpt(tOptions * opts, tOptDesc * od)
(void)opts;
(void)od;
}
-/* extracted from optmain.tlib near line 1245 */
+/* extracted from optmain.tlib near line 1250 */
/**
* The directory containing the data associated with genshellopt.
@@ -406,11 +406,11 @@ AO_gettext(char const * pz)
if (option_xlateable_txt.field_ct != 0) {
res = dgettext("libopts", pz);
if (res == pz)
- res = (char *)(void *)_(pz);
+ res = (char *)VOIDP(_(pz));
} else
- res = (char *)(void *)_(pz);
+ res = (char *)VOIDP(_(pz));
#else
- res = (char *)(void *)_(pz);
+ res = (char *)VOIDP(_(pz));
#endif
if (res == pz)
return res;
@@ -447,7 +447,7 @@ translate_option_strings(void)
* Do the translations. The first pointer follows the field count
* field. The field count field is the size of a pointer.
*/
- char ** ppz = (char**)(void*)&(option_xlateable_txt);
+ char ** ppz = (char**)VOIDP(&(option_xlateable_txt));
int ix = option_xlateable_txt.field_ct;
do {
@@ -457,16 +457,16 @@ translate_option_strings(void)
/* prevent re-translation and disable "libopts" domain lookup */
option_xlateable_txt.field_ct = 0;
- coerce_it((void*)&(opts->pzCopyright));
- coerce_it((void*)&(opts->pzCopyNotice));
- coerce_it((void*)&(opts->pzFullVersion));
- coerce_it((void*)&(opts->pzUsageTitle));
- coerce_it((void*)&(opts->pzExplain));
- coerce_it((void*)&(opts->pzDetail));
+ coerce_it(VOIDP(&(opts->pzCopyright)));
+ coerce_it(VOIDP(&(opts->pzCopyNotice)));
+ coerce_it(VOIDP(&(opts->pzFullVersion)));
+ coerce_it(VOIDP(&(opts->pzUsageTitle)));
+ coerce_it(VOIDP(&(opts->pzExplain)));
+ coerce_it(VOIDP(&(opts->pzDetail)));
{
tOptDesc * od = opts->pOptDesc;
for (ix = opts->optCt; ix > 0; ix--, od++)
- coerce_it((void*)&(od->pzText));
+ coerce_it(VOIDP(&(od->pzText)));
}
}
}
@@ -555,19 +555,19 @@ by the newly generated text. The first '#!' line will be regenerated.\n"));
puts(_("allocation of %d bytes failed\n"));
#line 53 "../init.c"
puts(_("AutoOpts function called without option descriptor\n"));
-#line 90 "../init.c"
+#line 86 "../init.c"
puts(_("\tThis exceeds the compiled library version: "));
-#line 88 "../init.c"
+#line 84 "../init.c"
puts(_("Automated Options Processing Error!\n"
"\t%s called AutoOpts function with structure version %d:%d:%d.\n"));
#line 80 "../autoopts.c"
puts(_("realloc of %d bytes at 0x%p failed\n"));
-#line 92 "../init.c"
+#line 88 "../init.c"
puts(_("\tThis is less than the minimum library version: "));
#line 121 "../version.c"
puts(_("Automated Options version %s\n"
"\tCopyright (C) 1999-2014 by Bruce Korb - all rights reserved\n"));
-#line 82 "../makeshell.c"
+#line 87 "../makeshell.c"
puts(_("(AutoOpts bug): %s.\n"));
#line 90 "../reset.c"
puts(_("optionResetOpt() called, but reset-option not configured"));
@@ -591,9 +591,9 @@ by the newly generated text. The first '#!' line will be regenerated.\n"));
puts(_("%s: Command line arguments required\n"));
#line 43 "../alias.c"
puts(_("%d %s%s options allowed\n"));
-#line 89 "../makeshell.c"
+#line 94 "../makeshell.c"
puts(_("%s error %d (%s) calling %s for '%s'\n"));
-#line 301 "../makeshell.c"
+#line 306 "../makeshell.c"
puts(_("interprocess pipe"));
#line 168 "../version.c"
puts(_("error: version option argument '%c' invalid. Use:\n"
@@ -671,9 +671,9 @@ by the newly generated text. The first '#!' line will be regenerated.\n"));
puts(_("Try '%s %s' for more information.\n"));
#line 45 "../alias.c"
puts(_("one %s%s option allowed\n"));
-#line 203 "../makeshell.c"
+#line 208 "../makeshell.c"
puts(_("standard output"));
-#line 938 "../makeshell.c"
+#line 943 "../makeshell.c"
puts(_("standard output"));
#line 274 "../usage.c"
puts(_("standard output"));
@@ -691,9 +691,9 @@ by the newly generated text. The first '#!' line will be regenerated.\n"));
puts(_("standard error"));
#line 175 "../version.c"
puts(_("standard error"));
-#line 203 "../makeshell.c"
+#line 208 "../makeshell.c"
puts(_("write"));
-#line 938 "../makeshell.c"
+#line 943 "../makeshell.c"
puts(_("write"));
#line 273 "../usage.c"
puts(_("write"));
@@ -745,7 +745,7 @@ by the newly generated text. The first '#!' line will be regenerated.\n"));
#line 380 "../usage.c"
puts(_("Options are specified by doubled hyphens and their name or by a single\n"
"hyphen and the flag character.\n"));
-#line 916 "../makeshell.c"
+#line 921 "../makeshell.c"
puts(_("\n"
"= = = = = = = =\n\n"
"This incarnation of genshell will produce\n"
OpenPOWER on IntegriCloud