Lines Matching +defs:val +defs:opt
72 set_option(char *name, char *val)
74 struct option *opt;
79 for (opt = options; opt->name; opt++) {
80 if (strcasecmp(name, opt->name) == 0) {
81 switch (opt->type) {
83 p = strdup(val);
84 *((char **)opt->address) = p;
87 if (val && *val == '\0')
90 n = atoi(val);
91 *((int *)opt->address) = n;
98 fd = open(val, O_WRONLY | O_CREAT, 0644);
102 *((int *)opt->address) = fd;