char *strdup __P((char *));
#endif
-static const char rcsid[] = RCSID;
struct option_value {
struct option_value *next;
free(*optptr);
*optptr = sv;
}
+ /* obfuscate original argument for things like password */
+ if (opt->flags & OPT_HIDE) {
+ memset(*argv, '?', strlen(*argv));
+ *argv = "********";
+ }
break;
case o_special_noarg:
char **argv;
{
if (phase == PHASE_INITIALIZE) {
- fprintf(stderr, "pppd version %s\n", VERSION);
+ fprintf(stdout, "pppd version %s\n", VERSION);
exit(0);
}
return 0;
c = getc(f);
}
+ word[MAXWORDLEN-1] = 0; /* make sure word is null-terminated */
/*
* End of the word: check for errors.
option_error("unexpected = in name: %s", arg);
return 0;
}
- if (arg == '\0') {
+ if (*arg == '\0') {
option_error("missing variable name for unset");
return 0;
}