Searched refs:optind (Results 1 - 25 of 736) sorted by relevance

1234567891011>>

/illumos-gate/usr/src/lib/libbc/libc/gen/common/
H A Doptind.c29 int optind = 1; variable
H A Dgetopt.c34 /* See lib/libc/gen/common/optind.c for next 3 definitions. */
37 extern int optind; /* index into parent argv vector */
52 if (optind >= nargc || *(place = nargv[optind]) != '-') {
57 ++optind;
72 ++optind;
86 ++optind;
90 else if (nargc <= ++optind) { /* no arg */
102 optarg = nargv[optind];
104 ++optind;
[all...]
/illumos-gate/usr/src/lib/libc/port/gen/
H A Dopt_data.c40 int optind = 1; variable
H A Dgetopt.c191 * argv[optind] is a null pointer
192 * *argv[optind] is not the character '-'
193 * argv[optind] points to the string "-"
194 * getopt() returns -1 without changing optind. If
195 * argv[optind] points to the string "--"
196 * getopt() returns -1 after incrementing optind.
199 if (optind >= argc || argv[optind][0] != '-' ||
200 argv[optind] == NULL || argv[optind][
[all...]
/illumos-gate/usr/src/cmd/mdb/common/libstand/
H A Dgetopt.c33 int opterr = 1, optind = 1, optopt = 0; variable
43 optind = 1;
56 if (optind >= argc || argv[optind][0] != '-' ||
57 argv[optind] == NULL || argv[optind][1] == '\0')
59 else if (strcmp(argv[optind], "--") == NULL) {
60 optind++;
64 optopt = c = (unsigned char)argv[optind][_sp];
68 if (argv[optind][
[all...]
/illumos-gate/usr/src/cmd/bnu/
H A Dgetopt.c43 int optind = 1; variable
57 if(optind >= argc ||
58 argv[optind][0] != '-' || argv[optind][1] == '\0')
60 else if(strcmp(argv[optind], "--") == NULL) {
61 optind++;
64 optopt = c = argv[optind][sp];
67 if(argv[optind][++sp] == '\0') {
68 optind++;
74 if(argv[optind][s
[all...]
/illumos-gate/usr/src/boot/lib/libstand/
H A Dgetopt.c41 optind = 1, /* index into parent argv vector */ variable
62 if (optind >= nargc || *(place = nargv[optind]) != '-') {
67 ++optind;
81 ++optind;
89 ++optind;
94 else if (nargc <= ++optind) { /* no arg */
103 optarg = nargv[optind];
105 ++optind;
/illumos-gate/usr/src/grub/grub-0.97/lib/
H A Dgetopt.c127 Otherwise, `optind' communicates from one call to the next
131 int optind = 1;
133 /* Formerly, initialization of getopt depended on optind==0, which
186 `--' can cause `getopt' to return -1 with `optind' != ARGC. */
300 The other is elements [last_nonopt,optind), which contains all
316 int top = optind;
386 first_nonopt += (optind - last_nonopt);
387 last_nonopt = optind;
405 first_nonopt = last_nonopt = optind;
472 updating `optind' an
130 int optind = 1; variable
[all...]
H A Dgetopt1.c114 int this_option_optind = optind ? optind : 1;
181 if (optind < argc)
184 while (optind < argc)
185 printf ("%s ", argv[optind++]);
/illumos-gate/usr/src/cmd/env/
H A Denv.c92 while (argv[optind] != NULL && strchr(argv[optind], '=') != NULL) {
93 if (putenv(argv[optind])) {
94 (void) perror(argv[optind]);
97 optind++;
101 if (argv[optind] == NULL) {
106 (void) execvp(argv[optind], &argv[optind]);
107 (void) fprintf(stderr, "%s: %s: %s\n", argv[0], argv[optind],
/illumos-gate/usr/src/lib/libast/common/include/
H A Dast_getopt.h35 extern int optind;
/illumos-gate/usr/src/cmd/lvm/metassist/controller/
H A Dgetopt_ext.c111 if (optind < argc) {
112 optarg = argv[optind];
118 optind++;
142 optarg = argv[optind-1];
/illumos-gate/usr/src/lib/libast/common/comp/
H A Dgetopt.c40 int optind = 1;
52 opt_info.index = (optind > 1 || optind == lastoptind) ? optind : 0;
74 lastoptind = optind = opt_info.index;
/illumos-gate/usr/src/cmd/avs/nsctl/
H A Dnscadm.c85 extern int optind, opterr;
107 if (optind == argc) {
112 if (strcoll(argv[optind], gettext("freeze")) == 0 ||
113 strcmp(argv[optind], "freeze") == 0) {
114 if (argc - optind != 2) {
119 is_chr_dev(argv[optind+1], "freeze");
120 rc = nsc_isfrozen(argv[optind+1]);
125 rc = nsc_freeze(argv[optind+1]);
132 "already frozen\n"), argv[optind+1]);
137 argv[optind
[all...]
/illumos-gate/usr/src/cmd/fm/fmadm/common/
H A Dreset.c49 if (argc - optind != 1)
52 if ((mod = strrchr(argv[optind], '/')) == NULL)
53 mod = argv[optind];
/illumos-gate/usr/src/cmd/link/
H A Dlink.c59 if (argc - optind != 2) {
64 if (res = link(argv[optind], argv[optind + 1]))
/illumos-gate/usr/src/cmd/dtrace/test/cmd/jdtrace/
H A DGetopt.java49 private int optind = 0; // args index field in class:Getopt
261 return optind;
321 * - the first character of argv[optind] is not '-'
322 * - argv[optind] is the string "-"
323 * getopt() returns -1 without changing optind if
324 * - argv[optind] is the string "--"
325 * getopt() returns -1 after incrementing optind
331 if (optind >= argc || args[optind].equals("-")) {
333 } else if (args[optind]
[all...]
/illumos-gate/usr/src/cmd/cmd-inet/usr.sbin/kssl/kssladm/
H A Dkssladm_delete.c69 pcnt = argc - optind;
71 port = argv[optind];
74 addr = argv[optind];
75 port = argv[optind + 1];
/illumos-gate/usr/src/cmd/head/
H A Dhead.c108 if ((strcmp(optarg, "--") == 0) || (optind > argc)) {
134 fileCount = argc - optind;
137 if ((argv[optind] == NULL) && around)
140 if (argv[optind] != NULL) {
143 if ((input = fopen(argv[optind], "r")) == NULL) {
144 perror(argv[optind]);
146 optind++;
158 (void) printf("==> %s <==\n", argv[optind]);
161 if (argv[optind] != NULL)
162 optind
[all...]
/illumos-gate/usr/src/cmd/lp/filter/postscript/common/
H A Dext.h49 extern int optind;
/illumos-gate/usr/src/cmd/lastcomm/
H A Dlastcomm.c68 return (lc_exacct(filename, argc, argv, optind));
76 return (lc_exacct(buf, argc, argv, optind));
87 return (lc_pacct("/var/adm/pacct", argc, argv, optind));
89 return (lc_exacct(buf, argc, argv, optind));
101 return (lc_pacct(filename, argc, argv, optind));
103 return (lc_exacct(filename, argc, argv, optind));
/illumos-gate/usr/src/cmd/sort/common/
H A Doptions.c255 * parse_old_field_spec() is getopt()-aware; it may modify the values of optind,
264 char *arg = argv[optind];
285 for (arg = argv[++optind]; optind < argc; arg = argv[optind]) {
291 optind++;
325 optind -= 1;
338 if (optarg == argv[optind - 1] + 2) {
339 optind -= 1;
341 optind
[all...]
/illumos-gate/usr/src/cmd/svr4pkg/pkgadm/
H A Dmain.c131 if (ci_streq(argv[optind], cmds[cur_cmd].c_name)) {
133 newargc = argc - optind;
134 newargv = argv + optind;
135 opterr = optind = 1; optopt = 0;
145 if (ci_streq(argv[optind], cert_cmds[cur_cmd].c_name)) {
147 newargc = argc - optind;
148 newargv = argv + optind;
149 opterr = optind = 1; optopt = 0;
155 log_msg(LOG_MSG_ERR, MSG_BAD_SUB, argv[optind]);
/illumos-gate/usr/src/cmd/ipf/tools/
H A Dipfzone.c25 extern int optind;
45 * getopt is also used here to set optind so that we can
54 if (optind < argc)
55 setzonename(argv[optind]);
58 * Reset optind and opterr so the next getopt call will go through all
61 optind = 1;
88 * Reset optind and opterr so the next getopt call will go through all
91 optind = 1;
/illumos-gate/usr/src/cmd/fs.d/smbclnt/smbutil/
H A Dlogin.c136 if (optind < argc) {
137 strcpy(tmp_arg, argv[optind]);
140 errx(1, gettext("failed to parse %s"), argv[optind]);
141 optind++;
143 if (optind != argc)
200 if (optind != argc)
216 if (optind < argc) {
217 strcpy(tmp_arg, argv[optind]);
220 errx(1, gettext("failed to parse %s"), argv[optind]);
221 optind
[all...]

Completed in 74 milliseconds

1234567891011>>