mirror of
https://github.com/zint/zint
synced 2024-11-16 20:57:25 +13:00
CODEONE/DATAMATRIX/MAILMARK/PLESSEY: fix some 32-bit/portability bugs
PLESSEY: add options NCR weighted mod-10, hide check digit(s) in HRT test suite: now runnable under MSVC 2019, 2017, 2015, MinGW/MSYS win32/README: update with MSVC 2019 and CMake instructions
This commit is contained in:
@ -780,8 +780,9 @@ static void test_utf8_to_eci_ucs2be(void) {
|
||||
int length = data[i].length != -1 ? data[i].length : (int) strlen(data[i].data);
|
||||
int out_length = length;
|
||||
int eci_length = get_eci_length(data[i].eci, (const unsigned char *) data[i].data, length);
|
||||
char *dest = alloca(eci_length + 1);
|
||||
char dest[1024];
|
||||
|
||||
assert_nonzero(eci_length + 1 <= 1024, "i:%d eci_length %d + 1 > 1024\n", i, eci_length);
|
||||
ret = utf8_to_eci(data[i].eci, (const unsigned char *) data[i].data, (unsigned char *) dest, &out_length);
|
||||
assert_equal(ret, data[i].ret, "i:%d utf8_to_eci ret %d != %d\n", i, ret, data[i].ret);
|
||||
if (ret == 0) {
|
||||
|
Reference in New Issue
Block a user