mirror of
https://github.com/zint/zint
synced 2024-11-16 20:57:25 +13:00
Check digit corrections from Massimo
This commit is contained in:
@ -272,11 +272,11 @@ int itf14(struct zint_symbol *symbol, unsigned char source[])
|
||||
|
||||
/* Calculate the check digit - the same method used for EAN-13 */
|
||||
|
||||
for (i = h - 1; i >= 0; i--)
|
||||
for (i = 12; i >= 0; i--)
|
||||
{
|
||||
count += ctoi(localstr[i]);
|
||||
|
||||
if (!((i%2) == 0))
|
||||
if ((i%2) == 0)
|
||||
{
|
||||
count += 2 * ctoi(localstr[i]);
|
||||
}
|
||||
|
Reference in New Issue
Block a user