X-Git-Url: http://git.marmaro.de/?a=blobdiff_plain;f=uip%2Faliasbr.c;h=85260d839d1bd68659699c13acb9b59f8338bc80;hb=d3ba09a465cb0e5fc9a74d0b152a7ed965f895cb;hp=07c5e035c8d050e06d8874496958eb3277b1dffe;hpb=b0b1dd37ff515578cf7cba51625189eb34a196cb;p=mmh diff --git a/uip/aliasbr.c b/uip/aliasbr.c index 07c5e03..85260d8 100644 --- a/uip/aliasbr.c +++ b/uip/aliasbr.c @@ -134,7 +134,8 @@ alias(char *file) register struct aka *ak = NULL; register FILE *fp; - if (*file!='/' && (strncmp(file, "./", 2) && strncmp(file, "../", 3))) + if (*file!='/' && (strncmp(file, "./", 2)!=0 && + strncmp(file, "../", 3)!=0)) file = etcpath(file); if ((fp = fopen(file, "r")) == NULL) { akerrst = file; @@ -359,7 +360,7 @@ addgroup(struct aka *ak, char *grp) struct passwd *pw; #endif /* DBMPWD */ for (hm = homehead; hm; hm = hm->h_next) - if (!strcmp(hm->h_name, gp)) { + if (strcmp(hm->h_name, gp)==0) { add_aka(ak, hm->h_name); break; } @@ -420,8 +421,8 @@ addall(struct aka *ak) Everyone = EVERYONE; for (hm = homehead; hm; hm = hm->h_next) - if (hm->h_uid > Everyone - && (noshell || strcmp(hm->h_shell, NoShell))) + if (hm->h_uid > Everyone && (noshell || + strcmp(hm->h_shell, NoShell)!=0)) add_aka(ak, hm->h_name); return homehead != NULL; @@ -466,7 +467,7 @@ add_aka(struct aka *ak, char *pp) register struct adr *ad, *ld; for (ad = ak->ak_addr, ld = NULL; ad; ld = ad, ad = ad->ad_next) - if (!strcmp(pp, ad->ad_text)) + if (strcmp(pp, ad->ad_text)==0) return; ad = (struct adr *) mh_xmalloc(sizeof(*ad));