free(buf);
return xstrdup(def_val);
}
- if (!c_strcasecmp(buf, "none")) {
+ if (c_strcasecmp(buf, "none") == 0) {
free(buf);
ctl->changed = 1;
return xstrdup("");
return;
}
s = getlogindefs_str("CHFN_RESTRICT", "");
- if (!strcmp(s, "yes")) {
+ if (strcmp(s, "yes") == 0) {
ctl->allow_room = ctl->allow_work = ctl->allow_home = 1;
return;
}
- if (!strcmp(s, "no")) {
+ if (strcmp(s, "no") == 0) {
ctl->allow_fullname = ctl->allow_room = ctl->allow_work = ctl->allow_home = 1;
return;
}