src/contrib/ntp/util/ntp-keygen-opts.c
/**
 * Translate all the translatable strings in the ntp_keygenOptions
 * structure defined above.  This is done only once.
 */
Translate all the translatable strings in the ntp_keygenOptions
structure defined above.  This is done only once.
Translate all the translatable strings in the ntp_keygenOptions structure defined above . This is done only once .
static void
translate_option_strings(void)
{
    tOptions * const opts = &ntp_keygenOptions;
    if (option_xlateable_txt.field_ct != 0) {
        char ** ppz = (char**)VOIDP(&(option_xlateable_txt));
        int     ix  = option_xlateable_txt.field_ct;
        do {
            ppz++; 
            *ppz = AO_gettext(*ppz);
        } while (--ix > 0);
        option_xlateable_txt.field_ct = 0;
        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(VOIDP(&(od->pzText)));
        }
    }
}
static void translate_option_strings ( void ) { tOptions * const opts = & ntp_keygenOptions ; if ( option_xlateable_txt . field_ct != 0 ) { char * * ppz = ( char * * ) VOIDP ( & ( option_xlateable_txt ) ) ; int ix = option_xlateable_txt . field_ct ; do { ppz ++ ; * ppz = AO_gettext ( * ppz ) ; } while ( -- ix > 0 ) ; option_xlateable_txt . field_ct = 0 ; 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 ( VOIDP ( & ( od -> pzText ) ) ) ; } } }
Translate all the translatable strings in the ntp_keygenOptions
 structure defined above.
Translate all the translatable strings in the ntp_keygenOptions structure defined above .
/*
     *  Guard against re-translation.  It won't work.  The strings will have
     *  been changed by the first pass through this code.  One shot only.
     */ /*
         *  Do the translations.  The first pointer follows the field count
         *  field.  The field count field is the size of a pointer.
         */ /* skip over field_ct */ /* prevent re-translation and disable "libopts" domain lookup */