This is an automated email from the ASF dual-hosted git repository.

mgrigorov pushed a commit to branch 8.5.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/8.5.x by this push:
     new c6c56f1  Change 'if' to 'else if'
c6c56f1 is described below

commit c6c56f1c5a0c00e8ff8aeac62ebfcee190f2ab86
Author: Martin Tzvetanov Grigorov <mgrigo...@apache.org>
AuthorDate: Tue Aug 25 14:29:13 2020 +0300

    Change 'if' to 'else if'
    
    b[pos] cannot be both '\\' and 0, so there is no need to make the second 
check if it was '\\'
---
 java/org/apache/catalina/connector/CoyoteAdapter.java | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/java/org/apache/catalina/connector/CoyoteAdapter.java 
b/java/org/apache/catalina/connector/CoyoteAdapter.java
index 7d9c8f2..46a7c9f 100644
--- a/java/org/apache/catalina/connector/CoyoteAdapter.java
+++ b/java/org/apache/catalina/connector/CoyoteAdapter.java
@@ -1163,8 +1163,7 @@ public class CoyoteAdapter implements Adapter {
                 } else {
                     return false;
                 }
-            }
-            if (b[pos] == (byte) 0) {
+            } else if (b[pos] == (byte) 0) {
                 return false;
             }
         }


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org

Reply via email to