mirror of
https://github.com/zint/zint
synced 2024-11-16 20:57:25 +13:00
Correct ISBN13 check digit
ISBN-13 check digit now correctly identifies '0'. Thanks to Kévin Sailly.
This commit is contained in:
parent
74047434b5
commit
5fe18d0ffa
@ -378,6 +378,7 @@ char isbn13_check(unsigned char source[]) /* For ISBN(13) only */
|
|||||||
|
|
||||||
check = sum % 10;
|
check = sum % 10;
|
||||||
check = 10 - check;
|
check = 10 - check;
|
||||||
|
if(check == 10) check = 0;
|
||||||
return itoc(check);
|
return itoc(check);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user