]> diplodocus.org Git - nmh/commitdiff
Don't `else' after return. Simplify control flow.
authorRalph Corderoy <ralph@inputplus.co.uk>
Thu, 20 Oct 2016 22:21:34 +0000 (23:21 +0100)
committerRalph Corderoy <ralph@inputplus.co.uk>
Thu, 20 Oct 2016 22:34:05 +0000 (23:34 +0100)
sbr/mf.c

index fa281766d8ada7a27eccae075259eabc3187a5ec..9e5cad8ce8dcaa23cae22e00c0feede2dc407e59 100644 (file)
--- a/sbr/mf.c
+++ b/sbr/mf.c
@@ -34,17 +34,18 @@ isfrom(const char *string)
 int
 lequal (const char *a, const char *b)
 {
 int
 lequal (const char *a, const char *b)
 {
-    for (; *a; a++, b++)
+    char c1, c2;
+
+    for (; *a; a++, b++) {
        if (*b == 0)
            return FALSE;
        if (*b == 0)
            return FALSE;
-       else {
-           char c1 = islower ((unsigned char) *a) ?
-                                       toupper ((unsigned char) *a) : *a;
-           char c2 = islower ((unsigned char) *b) ?
-                                       toupper ((unsigned char) *b) : *b;
-           if (c1 != c2)
-               return FALSE;
-       }
+        c1 = islower ((unsigned char) *a) ?
+                                    toupper ((unsigned char) *a) : *a;
+        c2 = islower ((unsigned char) *b) ?
+                                    toupper ((unsigned char) *b) : *b;
+        if (c1 != c2)
+            return FALSE;
+    }
 
     return (*b == 0);
 }
 
     return (*b == 0);
 }