(sec_login): fix loop and return value

git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@5180 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
Assar Westerlund
1998-11-02 00:57:47 +00:00
parent 1e3ca44412
commit beeb156b1a

View File

@@ -672,7 +672,7 @@ sec_login(char *host)
verbose = -1; /* shut up all messages this will produce (they
are usually not very user friendly) */
for(m = mechs; (*m)->name; m++) {
for(m = mechs; *m && (*m)->name; m++) {
app_data = realloc(app_data, (*m)->size);
if((*m)->init && (*(*m)->init)(app_data) != 0) {
printf("Skipping %s...\n", (*m)->name);
@@ -708,7 +708,7 @@ sec_login(char *host)
}
verbose = old_verbose;
return 0;
return *m == NULL;
}
void