/freebsd/contrib/ntp/sntp/libopts/ |
H A D | restore.c | 41 fixupSavedOptionArgs(tOptions * pOpts) in fixupSavedOptionArgs() argument 43 tOptions * p = pOpts->pSavedState; in fixupSavedOptionArgs() 44 tOptDesc * pOD = pOpts->pOptDesc; in fixupSavedOptionArgs() 45 int ct = pOpts->optCt; in fixupSavedOptionArgs() 55 tOptDesc * q = p->pOptDesc + (pOD - pOpts->pOptDesc); in fixupSavedOptionArgs() 59 tOptDesc * q = p->pOptDesc + (pOD - pOpts->pOptDesc); in fixupSavedOptionArgs() 66 tOptDesc * q = p->pOptDesc + (pOD - pOpts->pOptDesc); in fixupSavedOptionArgs() 97 optionSaveState(tOptions * pOpts) in optionSaveState() argument 99 tOptions * p = (tOptions *)pOpts->pSavedState; in optionSaveState() 102 size_t sz = sizeof(*pOpts) in optionSaveState() [all …]
|
H A D | env.c | 42 doPrognameEnv(tOptions * pOpts, teEnvPresetType type) in doPrognameEnv() argument 44 char const * env_opts = getenv(pOpts->pzPROGNAME); in doPrognameEnv() 67 sv_argc = (int)pOpts->origArgCt; in doPrognameEnv() 68 sv_argv = pOpts->origArgVect; in doPrognameEnv() 69 sv_flag = pOpts->fOptSet; in doPrognameEnv() 79 pOpts->origArgVect = VOIDP(v - sizeof(char *)); in doPrognameEnv() 81 pOpts->origArgCt = (unsigned int)pTL->tkn_ct + 1; in doPrognameEnv() 82 pOpts->fOptSet &= ~OPTPROC_ERRSTOP; in doPrognameEnv() 84 pOpts->curOptIdx = 1; in doPrognameEnv() 85 pOpts->pzCurOpt = NULL; in doPrognameEnv() [all …]
|
H A D | reset.c | 33 optionReset(tOptions * pOpts, tOptDesc * pOD) in optionReset() argument 38 pOD->pOptProc(pOpts, pOD); in optionReset() 40 pOpts->originalOptArgArray[ pOD->optIndex ].argString; in optionReset() 41 pOD->optCookie = pOpts->originalOptArgCookie[ pOD->optIndex ]; in optionReset() 47 optionResetEverything(tOptions * pOpts) in optionResetEverything() argument 49 tOptDesc * pOD = pOpts->pOptDesc; in optionResetEverything() 50 int ct = pOpts->presetOptCt; in optionResetEverything() 53 optionReset(pOpts, pOD); in optionResetEverything() 74 optionResetOpt(tOptions * pOpts, tOptDesc * pOD) in optionResetOpt() argument 82 if (pOpts <= OPTPROC_EMIT_LIMIT) in optionResetOpt() [all …]
|
H A D | check.c | 35 has_conflict(tOptions * pOpts, tOptDesc * od) in has_conflict() argument 41 tOptDesc * p = pOpts->pOptDesc + *(must++); in has_conflict() 43 const tOptDesc * ood = pOpts->pOptDesc + must[-1]; in has_conflict() 44 fprintf(stderr, zneed_fmt, pOpts->pzProgName, in has_conflict() 55 tOptDesc * p = pOpts->pOptDesc + *(cant++); in has_conflict() 57 const tOptDesc * ood = pOpts->pOptDesc + cant[-1]; in has_conflict() 58 fprintf(stderr, zconflict_fmt, pOpts->pzProgName, in has_conflict() 72 occurs_enough(tOptions * pOpts, tOptDesc * pOD) in occurs_enough() argument 74 (void)pOpts; in occurs_enough() 92 fprintf(stderr, zneed_more, pOpts->pzProgName, pOD->pz_Name, in occurs_enough() [all …]
|
H A D | find.c | 287 optionVendorOption(tOptions * pOpts, tOptDesc * pOD) in optionVendorOption() argument 292 if (pOpts <= OPTPROC_EMIT_LIMIT) in optionVendorOption() 301 if ( ((pOpts->fOptSet & OPTPROC_VENDOR_OPT) == 0) in optionVendorOption() 302 || ! SUCCESSFUL(opt_find_long(pOpts, vopt_str, &opt_st)) in optionVendorOption() 303 || ! SUCCESSFUL(get_opt_arg(pOpts, &opt_st)) ) in optionVendorOption() 305 fprintf(stderr, zIllVendOptStr, pOpts->pzProgName, vopt_str); in optionVendorOption() 306 (*pOpts->pUsageProc)(pOpts, EXIT_FAILURE); in optionVendorOption() 314 if (pOpts->fOptSet & OPTPROC_IMMEDIATE) { in optionVendorOption() 319 (void)handle_opt(pOpts, &opt_st); in optionVendorOption() 327 (void)handle_opt(pOpts, &opt_st); in optionVendorOption() [all …]
|
H A D | putshell.c | 258 print_enumeration(tOptions * pOpts, tOptDesc * pOD) in print_enumeration() argument 261 printf(OPT_VAL_FMT, pOpts->pzPROGNAME, pOD->pz_NAME); in print_enumeration() 272 printf(OPT_END_FMT, pOpts->pzPROGNAME, pOD->pz_NAME); in print_enumeration() 276 print_membership(tOptions * pOpts, tOptDesc * pOD) in print_membership() argument 281 printf(zOptNumFmt, pOpts->pzPROGNAME, pOD->pz_NAME, in print_membership() 308 print_stacked_arg(tOptions * pOpts, tOptDesc * pOD) in print_stacked_arg() argument 314 printf(zOptCookieCt, pOpts->pzPROGNAME, pOD->pz_NAME, ct); in print_stacked_arg() 317 printf(ARG_BY_NUM_FMT, pOpts->pzPROGNAME, pOD->pz_NAME, in print_stacked_arg() 320 printf(EXPORT_ARG_FMT, pOpts->pzPROGNAME, pOD->pz_NAME, in print_stacked_arg() 355 optionPutShell(tOptions * pOpts) in optionPutShell() argument [all …]
|
H A D | file.c | 41 check_existence(teOptFileType ftype, tOptions * pOpts, tOptDesc * pOD) in check_existence() argument 53 fserr_exit(pOpts->pzProgName, "stat", fname); in check_existence() 77 fserr_exit(pOpts->pzProgName, "stat", p); in check_existence() 87 fserr_exit(pOpts->pzProgName, "stat", fname); in check_existence() 102 open_file_fd(tOptions * pOpts, tOptDesc * pOD, tuFileMode mode) in open_file_fd() argument 106 fserr_exit(pOpts->pzProgName, "open", pOD->optArg.argString); in open_file_fd() 126 fopen_file_fp(tOptions * pOpts, tOptDesc * pOD, tuFileMode mode) in fopen_file_fp() argument 130 fserr_exit(pOpts->pzProgName, "fopen", pOD->optArg.argString); in fopen_file_fp() 159 optionFileCheck(tOptions * pOpts, tOptDesc * pOD, in optionFileCheck() argument 162 if (pOpts <= OPTPROC_EMIT_LIMIT) { in optionFileCheck() [all …]
|
H A D | proto.h | 41 has_conflict(tOptions * pOpts, tOptDesc * od); 44 occurs_enough(tOptions * pOpts, tOptDesc * pOD); 47 is_consistent(tOptions * pOpts); 114 enum_err(tOptions * pOpts, tOptDesc * pOD, 118 find_name(char const * name, tOptions * pOpts, tOptDesc * pOD, 122 set_memb_shell(tOptions * pOpts, tOptDesc * pOD, char const * const * paz_names, 140 doPrognameEnv(tOptions * pOpts, teEnvPresetType type); 144 tOptions * pOpts, teEnvPresetType type); 147 env_presets(tOptions * pOpts, teEnvPresetType type); 153 check_existence(teOptFileType ftype, tOptions * pOpts, tOptDesc * pOD); [all …]
|
H A D | numeric.c | 45 optionShowRange(tOptions * pOpts, tOptDesc * pOD, void * rng_table, int rng_ct) in optionShowRange() argument 55 if (pOpts != OPTPROC_EMIT_USAGE) { in optionShowRange() 56 if (pOpts <= OPTPROC_EMIT_LIMIT) in optionShowRange() 60 fprintf(option_usage_fp, zRangeErr, pOpts->pzProgName, in optionShowRange() 69 pz_indent = (pOpts != OPTPROC_EMIT_USAGE) in optionShowRange() 92 if (pOpts > OPTPROC_EMIT_LIMIT) in optionShowRange() 93 pOpts->pUsageProc(pOpts, EXIT_FAILURE); in optionShowRange()
|
H A D | enum.c | 37 enum_err(tOptions * pOpts, tOptDesc * pOD, in enum_err() argument 48 if (pOpts > OPTPROC_EMIT_LIMIT) in enum_err() 49 fprintf(option_usage_fp, pz_enum_err_fmt, pOpts->pzProgName, in enum_err() 134 if (pOpts > OPTPROC_EMIT_LIMIT) { in enum_err() 137 (*(pOpts->pUsageProc))(pOpts, EXIT_FAILURE); in enum_err() 160 find_name(char const * name, tOptions * pOpts, tOptDesc * pOD, in find_name() argument 178 enum_err(pOpts, pOD, paz_names, (int)name_ct); in find_name() 212 enum_err(pOpts, pOD, paz_names, (int)name_ct); in find_name() 259 optionEnumerationVal(tOptions * pOpts, tOptDesc * pOD, in optionEnumerationVal() argument 268 switch ((uintptr_t)pOpts) { in optionEnumerationVal() [all …]
|
H A D | usage.c | 173 do_gnu_usage(tOptions * pOpts) in do_gnu_usage() argument 175 return (pOpts->fOptSet & OPTPROC_GNUUSAGE) ? true : false; in do_gnu_usage() 183 skip_misuse_usage(tOptions * pOpts) in skip_misuse_usage() argument 185 return (pOpts->fOptSet & OPTPROC_MISUSE) ? true : false; in skip_misuse_usage() 201 optionOnlyUsage(tOptions * pOpts, int ex_code) in optionOnlyUsage() argument 205 set_usage_flags(pOpts, NULL); in optionOnlyUsage() 207 skip_misuse_usage(pOpts)) in optionOnlyUsage() 213 if (do_gnu_usage(pOpts)) in optionOnlyUsage() 214 (void)setGnuOptFmts(pOpts, &pOptTitle); in optionOnlyUsage() 216 (void)setStdOptFmts(pOpts, &pOptTitle); in optionOnlyUsage() [all …]
|
/freebsd/contrib/ntp/libntp/ |
H A D | ntp_libopts.c | 28 tOptions * pOpts, in ntpOptionProcess() argument 33 return optionProcess(pOpts, argc, argv); in ntpOptionProcess() 48 tOptions * pOpts, in ntpOptionPrintVersion() argument 52 UNUSED_ARG(pOpts); in ntpOptionPrintVersion()
|
/freebsd/contrib/ntp/include/ |
H A D | ntp_libopts.h | 11 extern int ntpOptionProcess(tOptions *pOpts, int argc,
|
/freebsd/contrib/ntp/sntp/libopts/autoopts/ |
H A D | options.h | 445 typedef void (tOptProc)(tOptions * pOpts, tOptDesc * pOptDesc); 457 typedef void (tUsageProc)(tOptions * pOpts, int exitCode);
|