• Home
  • Raw
  • Download

Lines Matching refs:toys

26 struct toy_context toys;  variable
73 toys.which = which; in toy_singleinit()
74 toys.argv = argv; in toy_singleinit()
79 if (CFG_TOYBOX && toys.which == toy_list && toys.argv[2]) in toy_singleinit()
80 if (!(toys.which = toy_find(toys.argv[2]))) return; in toy_singleinit()
87 toys.optargs = argv+1; in toy_singleinit()
88 for (toys.optc = 0; toys.optargs[toys.optc]; toys.optc++); in toy_singleinit()
90 toys.old_umask = umask(0); in toy_singleinit()
91 if (!(which->flags & TOYFLAG_UMASK)) umask(toys.old_umask); in toy_singleinit()
92 toys.signalfd--; in toy_singleinit()
93 toys.toycount = ARRAY_LEN(toy_list); in toy_singleinit()
99 void *oldwhich = toys.which; in toy_init()
104 if (!toys.which) toys.which = toy_list; in toy_init()
112 toys.wasroot++; in toy_init()
122 if (argv<toys.optargs || argv>toys.optargs+toys.optc) free(toys.optargs); in toy_init()
123 memset(&toys, 0, offsetof(struct toy_context, rebound)); in toy_init()
140 if (toys.stacktop && labs((char *)toys.stacktop-(char *)&which)>6000) in toy_exec()
144 if (toys.which && (which->flags&TOYFLAG_ROOTONLY) && toys.wasroot) return; in toy_exec()
148 if (toys.which) toys.which->toy_main(); in toy_exec()
161 if (toys.argv[1]) toy_exec(toys.argv+1); in toybox_main()
164 toys.which = toy_list; in toybox_main()
166 if (toys.argv[1]) { in toybox_main()
167 if (!strcmp("--version", toys.argv[1])) { in toybox_main()
171 if (toys.argv[1][0] != '-') { in toybox_main()
172 toys.exitval = 127; in toybox_main()
173 error_exit("Unknown command %s", toys.argv[1]); in toybox_main()
181 if (toys.argv[1]) { in toybox_main()
203 toys.stacktop = &stack; in main()
212 toys.stacktop = 0; in main()
219 toys.argv = argv-1; in main()