#181 OSS-Fuzz AZTEC fix, check binary_string buffer not full using az_binary_append() func

This commit is contained in:
gitlost 2020-03-28 22:50:55 +00:00
parent 20d5dcc50f
commit 56f0616747
4 changed files with 596 additions and 106 deletions

View file

@ -2,7 +2,7 @@
/*
libzint - the open source barcode library
Copyright (C) 2008-2019 Robin Stuart <rstuart114@gmail.com>
Copyright (C) 2008-2020 Robin Stuart <rstuart114@gmail.com>
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
@ -1386,7 +1386,7 @@ static int rss_binary_string(struct zint_symbol *symbol, char source[], char bin
rest of the data (if any) goes into a general-purpose data compaction field */
j = 0;
for (i = read_posn; i < strlen(source); i++) {
for (i = read_posn; i < (int) strlen(source); i++) {
general_field[j] = source[i];
j++;
}