Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
1.0.0-RC2
-
None
Description
Our tool DeepTect has detected a piece of buggy code snippet, in which the if and else branches has the same condition.
Path: directory-ldap-api/util/src/main/java/org/apache/directory/api/util/Unicode.java
public static char bytesToChar( byte[] bytes, int pos ){ ... else if ( ( bytes[pos] & UTF8_FIVE_BYTES_MASK ) == UTF8_FIVE_BYTES ){ // Five bytes char ... } else if ( ( bytes[pos] & UTF8_FIVE_BYTES_MASK ) == UTF8_FIVE_BYTES ){ // Six bytes char ... }