Authentication modes are given as strings.

git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@434 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
Unknown User d91-jda
1996-04-25 20:47:33 +00:00
parent d34095397d
commit e132541838

View File

@@ -282,15 +282,14 @@ main(int argc, char **argv, char **envp)
switch (ch) {
case 'a':
{
int tmp;
if(isdigit(optarg[0])){
tmp = atoi(optarg);
if(tmp >= 0 && tmp <= 2){
auth_level = tmp;
break;
}
}
warnx("bad value for -a");
if(strcmp(optarg, "none") == 0)
auth_level = 0;
else if(strcmp(optarg, "safe") == 0)
auth_level = 1;
else if(strcmp(optarg, "user") == 0)
auth_level = 2;
else
warnx("bad value for -a");
break;
}
case 'd':