Lines Matching refs:argv
14 int poptDupArgv(int argc, const char **argv,
17 size_t nb = (argc + 1) * sizeof(*argv);
22 if (argc <= 0 || argv == NULL) /* XXX can't happen */
25 if (argv[i] == NULL)
27 nb += strlen(argv[i]) + 1;
34 dst += (argc + 1) * sizeof(*argv);
39 dst += strlen(strcpy(dst, argv[i])) + 1;
62 const char ** argv = malloc(sizeof(*argv) * argvAlloced);
68 if (argv == NULL) return rc;
69 argv[argc] = buf;
85 if (*argv[argc] != '\0') {
89 argv = realloc(argv, sizeof(*argv) * argvAlloced);
90 if (argv == NULL) goto exit;
92 argv[argc] = buf;
112 if (strlen(argv[argc])) {
116 rc = poptDupArgv(argc, argv, argcPtr, argvPtr);
119 if (argv) free(argv);