diff --git a/modules/global-db/dap_chain_global_db.c b/modules/global-db/dap_chain_global_db.c index ffdd19273dcf74056ce73b2f1542e08268142140..a10589da986c7e023accae2b0b62278983d7b859 100644 --- a/modules/global-db/dap_chain_global_db.c +++ b/modules/global-db/dap_chain_global_db.c @@ -859,6 +859,8 @@ char* dap_chain_global_db_hash(const uint8_t *data, size_t data_size) void* dap_db_log_unpack(const void *a_data, size_t a_data_size, size_t *a_store_obj_count) { const dap_store_obj_pkt_t *l_pkt = (const dap_store_obj_pkt_t*) a_data; + if (! l_pkt) + return NULL; if(!l_pkt || l_pkt->data_size != ((size_t) a_data_size - sizeof(dap_store_obj_pkt_t))) return NULL; size_t l_store_obj_count = 0;