gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[libmicrohttpd2] 05/21: mhd_str.c: minor readability improvements


From: Admin
Subject: [libmicrohttpd2] 05/21: mhd_str.c: minor readability improvements
Date: Fri, 13 Jun 2025 23:38:13 +0200

This is an automated email from the git hooks/post-receive script.

karlson2k pushed a commit to branch master
in repository libmicrohttpd2.

commit ee27dba98e5a2d128b4c40e96d20e1babbf1207b
Author: Evgeny Grin (Karlson2k) <k2k@drgrin.dev>
AuthorDate: Wed Jun 11 17:38:15 2025 +0200

    mhd_str.c: minor readability improvements
---
 src/mhd2/mhd_str.c | 16 +++++++++-------
 1 file changed, 9 insertions(+), 7 deletions(-)

diff --git a/src/mhd2/mhd_str.c b/src/mhd2/mhd_str.c
index 7935135..f6f3589 100644
--- a/src/mhd2/mhd_str.c
+++ b/src/mhd2/mhd_str.c
@@ -2142,21 +2142,23 @@ base64_char_to_value_ (uint8_t c)
   {
     if ('A' <= c)
       return (mhd_base64_map_type) ((c - 'A') + 0);
-    if ('0' <= c)
+    else if ('0' <= c)
     {
       if ('9' >= c)
         return (mhd_base64_map_type) ((c - '0') + 52);
-      if ('=' == c)
+      else if ('=' == c)
         return -2;
-      return -1;
+      else
+        return -1;
     }
-    if ('+' == c)
+    else if ('+' == c)
       return 62;
-    if ('/' == c)
+    else if ('/' == c)
       return 63;
-    return -1;
+    else
+      return -1;
   }
-  if (('z' >= c) && ('a' <= c))
+  else if (('z' >= c) && ('a' <= c))
     return (mhd_base64_map_type) ((c - 'a') + 26);
   return -1;
 }

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]