Commit a9082605 authored by anonymous's avatar anonymous
Browse files

Fix possible integer overflow

parent ecf82be0
......@@ -209,7 +209,10 @@ uint32_t diff_hashdb_load(uint8_t *hashname, uint8_t *fname, uint64_t offset,
str_print_hex(str, sha_hdr.digest, sizeof(digest))); = FETCH4((uint8_t *)&;
if ( < sizeof(sha_hdr.len)) {
BD_DEBUG(DBG_BDPLUS,"[diff] invalid data in hash_db.bin\n");
if (!memcmp(digest, sha_hdr.digest, sizeof(digest))) {
// Found the digest we are looking for
sha_hdr.len = FETCH4((uint8_t *)&sha_hdr.len);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment