Lines Matching full:which

33   if (!toys.which && strstart(&name, toy_list->name)) return toy_list;  in toy_find()
88 int i = toys.which-toy_list; in show_help()
111 else fprintf(out, "%s see %s\n", toys.which->name, s); in show_help()
128 toys.which = toy_list; in unknown()
135 long flags = toys.which->flags; in check_help()
138 if (!CFG_TOYBOX || toys.which!=toy_list) if (flags&TOYFLAG_NOHELP) return; in check_help()
141 if (CFG_TOYBOX && toys.which == toy_list && arg[1]) { in check_help()
142 toys.which = 0; in check_help()
143 if (!(toys.which = toy_find(arg[1]))) unknown(arg[1]); in check_help()
155 sprintf(toybuf, " (is not GNU %s 9.0)", toys.which->name); in check_help()
162 void toy_singleinit(struct toy_list *which, char *argv[]) in toy_singleinit() argument
164 toys.which = which; in toy_singleinit()
168 if (NEED_OPTIONS && which->options) get_optflags(); in toy_singleinit()
175 if (!(CFG_TOYBOX && which == toy_list) && !(which->flags & TOYFLAG_NOFORK)) { in toy_singleinit()
180 if (!(which->flags & TOYFLAG_UMASK)) umask(toys.old_umask); in toy_singleinit()
189 if (which->flags & TOYFLAG_LINEBUF) btype = _IOLBF; in toy_singleinit()
190 else if (which->flags & TOYFLAG_NOBUF) btype = _IONBF; in toy_singleinit()
197 void toy_init(struct toy_list *which, char *argv[]) in toy_init() argument
199 void *oldwhich = toys.which; in toy_init()
203 if (!toys.which) toys.which = toy_list; in toy_init()
207 if (!(which->flags & TOYFLAG_STAYROOT)) { in toy_init()
213 } else if (CFG_TOYBOX_DEBUG && uid && which != toy_list) in toy_init()
216 if ((which->flags & TOYFLAG_NEEDROOT) && euid) { in toy_init()
217 toys.which = which; in toy_init()
227 toy_singleinit(which, argv); in toy_init()
232 void toy_exec_which(struct toy_list *which, char *argv[]) in toy_exec_which() argument
234 // Return if we can't find it (which includes no multiplexer case), in toy_exec_which()
235 if (!which || (which->flags&TOYFLAG_NOFORK)) return; in toy_exec_which()
244 if (labs((long)toys.stacktop-(long)&which)>24000) return; in toy_exec_which()
247 if (toys.which && (which->flags&TOYFLAG_ROOTONLY) && toys.wasroot) return; in toy_exec_which()
250 toy_init(which, argv); in toy_exec_which()
251 if (toys.which) toys.which->toy_main(); in toy_exec_which()
270 // (Leave toys.which null to disable suid return logic.) in toybox_main()
282 toys.which = toy_list; in toybox_main()