From 3f2fe30962d6e06854759bc00209747f70f21d1f Mon Sep 17 00:00:00 2001 From: Ian Darwin Date: Fri, 28 Aug 1987 21:08:24 +0000 Subject: [PATCH] Minor stylistic tweaking. --- src/file.c | 2 +- src/softmagic.c | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/file.c b/src/file.c index 65af4d00..65b530be 100644 --- a/src/file.c +++ b/src/file.c @@ -153,7 +153,7 @@ readit: */ ckfputs("data", stdout); } - if (0 != strcmp("-", inname)) { + if (strcmp("-", inname) != 0) { /* * Restore access, modification times if we read it. */ diff --git a/src/softmagic.c b/src/softmagic.c index b6e45a05..f03f4600 100644 --- a/src/softmagic.c +++ b/src/softmagic.c @@ -110,7 +110,8 @@ struct magic *m; l = 0; /* What we want here is: * v = strncmp(m->value.s, p->s, m->vallen); - * but ignoring any nulls. bcmp doesn't give -/+/0. + * but ignoring any nulls. bcmp doesn't give -/+/0 + * and isn't universally available anyway. */ { register unsigned char *a = (unsigned char*)m->value.s; @@ -118,7 +119,8 @@ struct magic *m; register int len = m->vallen; while (--len >= 0) - if (0 != (v = *b++ - *a++)) break; + if ((v = *b++ - *a++) != 0) + break; } break; default: -- 2.40.0