Home
last modified time | relevance | path

Searched refs:argc (Results 1 – 25 of 252) sorted by relevance

1234567891011

/system/vold/
DCryptCommandListener.cpp62 void CryptCommandListener::dumpArgs(int argc, char **argv, int argObscure) { in dumpArgs() argument
68 for (i = 0; i < argc; i++) { in dumpArgs()
82 if (i != (argc -1)) { in dumpArgs()
128 static bool check_argc(SocketClient *cli, const std::string &subcommand, int argc, in check_argc() argument
137 if (argc == expected) { in check_argc()
173 int argc, char **argv) { in runCommand() argument
179 if (argc < 2) { in runCommand()
188 if (!check_argc(cli, subcommand, argc, 3, "<passwd>")) return 0; in runCommand()
189 dumpArgs(argc, argv, 2); in runCommand()
192 if (!check_argc(cli, subcommand, argc, 2, "")) return 0; in runCommand()
[all …]
DCommandListener.cpp69 void CommandListener::dumpArgs(int argc, char **argv, int argObscure) { in dumpArgs() argument
75 for (i = 0; i < argc; i++) { in dumpArgs()
89 if (i != (argc -1)) { in dumpArgs()
142 int argc, char **argv) { in runCommand() argument
143 dumpArgs(argc, argv, -1); in runCommand()
145 if (argc < 2) { in runCommand()
165 } else if (cmd == "partition" && argc > 3) { in runCommand()
179 if (argc < 4) { in runCommand()
188 } else if (cmd == "mkdirs" && argc > 2) { in runCommand()
192 } else if (cmd == "user_added" && argc > 3) { in runCommand()
[all …]
DCommandListener.h30 static void dumpArgs(int argc, char **argv, int argObscure);
37 int runCommand(SocketClient *c, int argc, char ** argv);
44 int runCommand(SocketClient *c, int argc, char ** argv);
51 int runCommand(SocketClient *c, int argc, char ** argv);
60 int runCommand(SocketClient *c, int argc, char ** argv);
67 int runCommand(SocketClient *c, int argc, char ** argv);
74 int runCommand(SocketClient *c, int argc, char ** argv);
81 int runCommand(SocketClient *c, int argc, char ** argv);
Dvdc.cpp40 static int do_cmd(int sock, int argc, char **argv);
44 int main(int argc, char **argv) { in main() argument
51 wait_for_socket = argc > 1 && strcmp(argv[1], "--wait") == 0; in main()
54 argc--; in main()
57 if (argc < 2) { in main()
81 exit(do_cmd(sock, argc, argv)); in main()
85 static int do_cmd(int sock, int argc, char **argv) { in do_cmd() argument
89 for (int i = 1; i < argc; i++) { in do_cmd()
98 if (i < argc - 1) { in do_cmd()
/system/bt/tools/hci/
Dmain.c11 typedef int (*handler_t)(int argc, char **argv);
26 static int help(int argc, char **argv);
27 static int set_discoverable(int argc, char **argv);
28 static int set_name(int argc, char **argv);
29 static int set_pcm_loopback(int argc, char **argv);
30 static int set_sco_route(int argc, char **argv);
44 static int help(int argc, char **argv) { in help() argument
45 if (!argc) { in help()
60 static int set_discoverable(int argc, char **argv) { in set_discoverable() argument
61 if (argc != 1) { in set_discoverable()
[all …]
/system/netd/server/
DCommandListener.cpp93 int runCommand(SocketClient *c, int argc, char **argv) { in runCommand() argument
95 return mWrappedCmd->runCommand(c, argc, argv); in runCommand()
253 int argc, char **argv) { in runCommand() argument
254 if (argc < 2) { in runCommand()
280 if (argc < 3) { in runCommand()
333 if (argc < 4) { in runCommand()
363 for (int i = index; i < argc; i++) { in runCommand()
410 if (argc != 4) { in runCommand()
425 if (argc != 4) { in runCommand()
441 if (argc != 4) { in runCommand()
[all …]
DCommandListener.h53 int runCommand(SocketClient *c, int argc, char ** argv);
60 int runCommand(SocketClient *c, int argc, char ** argv);
67 int runCommand(SocketClient *c, int argc, char ** argv);
74 int runCommand(SocketClient *c, int argc, char ** argv);
81 int runCommand(SocketClient *c, int argc, char ** argv);
88 int runCommand(SocketClient *c, int argc, char ** argv);
95 int runCommand(SocketClient *c, int argc, char ** argv);
102 int runCommand(SocketClient *c, int argc, char ** argv);
113 int runCommand(SocketClient *c, int argc, char ** argv);
120 int runCommand(SocketClient *c, int argc, char ** argv);
[all …]
Dndc.c36 static int do_cmd(int sock, int argc, char **argv);
38 int main(int argc, char **argv) { in main() argument
42 if (argc < 2) in main()
57 if (argc < 3) usage(argv[0]); in main()
64 exit(do_cmd(sock, argc-cmdOffset, &(argv[cmdOffset]))); in main()
67 static int do_cmd(int sock, int argc, char **argv) { in do_cmd() argument
85 for (i = 1; i < argc; i++) { in do_cmd()
96 (i == (argc - 1)) ? "" : " ") < 0) { in do_cmd()
DIdletimerController.cpp125 int IdletimerController::runIpxtablesCmd(int argc, const char **argv) { in runIpxtablesCmd() argument
130 resIpv4 = android_fork_execvp(argc, (char **)argv, NULL, false, false); in runIpxtablesCmd()
134 resIpv6 = android_fork_execvp(argc, (char **)argv, NULL, false, false); in runIpxtablesCmd()
138 argc--; argv++; in runIpxtablesCmd()
139 for (; argc; argc--, argv++) { in runIpxtablesCmd()
/system/extras/tests/memtest/
Dmemtest.cpp63 int copy_bandwidth(int argc, char** argv);
64 int write_bandwidth(int argc, char** argv);
65 int read_bandwidth(int argc, char** argv);
66 int per_core_bandwidth(int argc, char** argv);
67 int multithread_bandwidth(int argc, char** argv);
68 int malloc_test(int argc, char** argv);
69 int madvise_test(int argc, char** argv);
70 int stack_smasher_test(int argc, char** argv);
71 int crawl_test(int argc, char** argv);
72 int fp_test(int argc, char** argv);
[all …]
Dbandwidth.cpp66 bool processBandwidthOptions(int argc, char** argv, option_t options[], in processBandwidthOptions() argument
68 for (int i = 1; i < argc; i++) { in processBandwidthOptions()
75 if (i == argc - 1) { in processBandwidthOptions()
211 bool processThreadArgs(int argc, char** argv, option_t options[], in processThreadArgs() argument
217 if (!processBandwidthOptions(argc, argv, options, values)) { in processThreadArgs()
295 int per_core_bandwidth(int argc, char** argv) { in per_core_bandwidth() argument
297 if (!processThreadArgs(argc, argv, per_core_opts, &values)) { in per_core_bandwidth()
333 int multithread_bandwidth(int argc, char** argv) { in multithread_bandwidth() argument
335 if (!processThreadArgs(argc, argv, multithread_opts, &values)) { in multithread_bandwidth()
368 bool run_bandwidth_benchmark(int argc, char** argv, const char *name, in run_bandwidth_benchmark() argument
[all …]
/system/core/adb/
Dcommandline.cpp59 static int install_app(TransportType t, const char* serial, int argc, const char** argv);
60 static int install_multiple_app(TransportType t, const char* serial, int argc, const char** argv);
61 static int uninstall_app(TransportType t, const char* serial, int argc, const char** argv);
62 static int install_app_legacy(TransportType t, const char* serial, int argc, const char** argv);
63 static int uninstall_app_legacy(TransportType t, const char* serial, int argc, const char** argv);
714 static int adb_shell(int argc, const char** argv) { in adb_shell() argument
732 --argc; in adb_shell()
736 while (argc) { in adb_shell()
738 if (argc < 2 || !(strlen(argv[1]) == 1 || strcmp(argv[1], "none") == 0)) { in adb_shell()
743 argc -= 2; in adb_shell()
[all …]
/system/core/toolbox/
Dstart_stop.cpp16 static int start_stop(bool start, int argc, char* argv[]) { in start_stop() argument
19 if (argc > 2) { in start_stop()
21 } else if (argc == 2) { in start_stop()
37 extern "C" int start_main(int argc, char* argv[]) { in start_main() argument
38 return start_stop(true, argc, argv); in start_main()
41 extern "C" int stop_main(int argc, char* argv[]) { in stop_main() argument
42 return start_stop(false, argc, argv); in stop_main()
Dtoolbox.c9 static int toolbox_main(int argc, char **argv) in toolbox_main() argument
12 if (argc > 1) { in toolbox_main()
13 return main(argc - 1, argv + 1); in toolbox_main()
43 int main(int argc, char **argv) in main() argument
54 if((argc > 1) && (argv[1][0] == '@')) { in main()
56 argc--; in main()
66 return tools[i].func(argc, argv); in main()
Dr.c22 int main(int argc, char *argv[]) in main() argument
24 if(argc < 2) return usage(); in main()
29 argc--; in main()
33 argc--; in main()
37 if(argc < 2) return usage(); in main()
55 if(argc > 2) { in main()
/system/core/fs_mgr/
Dfs_mgr_main.c35 static void parse_options(int argc, char *argv[], int *a_flag, int *u_flag, int *n_flag, in parse_options() argument
40 if (argc <= 1) { in parse_options()
45 if (argc != 3) { in parse_options()
51 if (argc != 5) { in parse_options()
59 if (argc != 3) { in parse_options()
78 int main(int argc, char *argv[]) in main() argument
91 parse_options(argc, argv, &a_flag, &u_flag, &n_flag, &n_name, &n_blk_dev); in main()
94 fstab_file = argv[argc - 1]; in main()
/system/extras/bootctl/
Dbootctl.c31 static void usage(FILE* where, int argc, char* argv[]) in usage() argument
152 static int parse_slot(int pos, int argc, char *argv[]) in parse_slot() argument
154 if (pos > argc - 1) { in parse_slot()
155 usage(stderr, argc, argv); in parse_slot()
162 usage(stderr, argc, argv); in parse_slot()
169 int main(int argc, char *argv[]) in main() argument
175 if (argc < 2) { in main()
176 usage(stderr, argc, argv); in main()
197 return do_set_active_boot_slot(module, parse_slot(2, argc, argv)); in main()
199 return do_set_slot_as_unbootable(module, parse_slot(2, argc, argv)); in main()
[all …]
/system/tools/aidl/
Doptions.cpp64 unique_ptr<JavaOptions> JavaOptions::Parse(int argc, const char* const* argv) { in Parse() argument
68 if (argc >= 2 && 0 == strcmp(argv[1], "--preprocess")) { in Parse()
69 if (argc < 4) { in Parse()
73 for (int i = 3; i < argc; i++) { in Parse()
82 while (i < argc) { in Parse()
133 if (i < argc) { in Parse()
147 if (i < argc) { in Parse()
161 if (i != argc) { in Parse()
163 (i == argc - 1 ? (const char*)"" : (const char*)"s")); in Parse()
164 for (; i < argc - 1; i++) { in Parse()
[all …]
/system/security/keystore/
Dkeystore_cli.cpp64 if (argc < 3) { \
82 if (argc < 3) { \
100 if (argc < 3) { \
105 if (argc > 3) { \
123 if (argc < 3) { \
130 if (argc > 3) { \
153 if (argc < 3) { \
174 if (argc < 3) { \
214 int main(int argc, char* argv[]) in main() argument
216 if (argc < 2) { in main()
[all …]
/system/core/logwrapper/
Dlogwrapper.c51 int main(int argc, char* argv[]) { in main() argument
59 while ((ch = getopt(argc, argv, "adk")) != -1) { in main()
76 argc -= optind; in main()
79 if (argc < 1) { in main()
83 rc = android_fork_execvp_ext(argc, &argv[0], &status, true, in main()
/system/core/logd/
DCommandListener.cpp82 int argc, char **argv) { in runCommand() argument
89 if (argc < 2) { in runCommand()
110 int argc, char **argv) { in runCommand() argument
112 if (argc < 2) { in runCommand()
136 int argc, char **argv) { in runCommand() argument
143 if (argc < 3) { in runCommand()
170 int argc, char **argv) { in runCommand() argument
172 if (argc < 2) { in runCommand()
205 int argc, char **argv) { in runCommand() argument
214 if (argc > 1) { in runCommand()
[all …]
/system/core/libsparse/
Dsimg2img.c38 int main(int argc, char *argv[]) in main() argument
45 if (argc < 3) { in main()
50 out = open(argv[argc - 1], O_WRONLY | O_CREAT | O_TRUNC | O_BINARY, 0664); in main()
52 fprintf(stderr, "Cannot open output file %s\n", argv[argc - 1]); in main()
56 for (i = 1; i < argc - 1; i++) { in main()
/system/core/libsysutils/src/
DFrameworkListener.cpp87 int argc = 0; in dispatchCommand() local
152 if (argc >= CMD_ARGS_MAX) in dispatchCommand()
154 argv[argc++] = strdup(tmp); in dispatchCommand()
164 if (argc >= CMD_ARGS_MAX) in dispatchCommand()
166 argv[argc++] = strdup(tmp); in dispatchCommand()
168 for (int k = 0; k < argc; k++) { in dispatchCommand()
188 if (c->runCommand(cli, argc, argv)) { in dispatchCommand()
197 for (j = 0; j < argc; j++) in dispatchCommand()
/system/extras/multinetwork/
Dcommon.cpp71 bool Arguments::parseArguments(int argc, const char* argv[]) { in parseArguments() argument
72 if (argc < 1 || argv == nullptr) { return false; } in parseArguments()
74 for (int i = 1; i < argc; i++) { in parseArguments()
77 if (argc == i) break; in parseArguments()
85 if (argc == i) break; in parseArguments()
97 if (argc == i) break; in parseArguments()
/system/extras/perfprofd/
Dperfprofdmain.cc18 extern int perfprofd_main(int argc, char** argv);
20 int main(int argc, char** argv) in main() argument
22 return perfprofd_main(argc, argv); in main()

1234567891011