[ 
https://issues.apache.org/jira/browse/CODEC-256?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16799476#comment-16799476
 ] 

Gary Gregory commented on CODEC-256:
------------------------------------

[~aschnur],

Thank you for your report.

It would be best if you could provide a PR on GitHub with a unit test that 
fails without your main changes.

Gary

> ColognePhonetic.encode() calculates wrong code
> ----------------------------------------------
>
>                 Key: CODEC-256
>                 URL: https://issues.apache.org/jira/browse/CODEC-256
>             Project: Commons Codec
>          Issue Type: Bug
>    Affects Versions: 1.12
>         Environment: Java 8u181 64, Windows 7 Professional 64
>            Reporter: Andreas Schnur
>            Priority: Major
>         Attachments: ColognePhonetic.java
>
>
> Example String: "ARTMANN". Code of M is 6, Code of A is Zero (and therefore 
> is left out), Code of N is 6 and should be left out because 6 is previous, 
> but Code assumes wrongly 0 as previous (which was left out). So the result is 
> 07266, but has to be 0726 (see Description of algorithm in class).
> Solution: In method colognePhonetic() move the last two LOC into if-block 
> above, see attached version of class.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to