Coverity issue: 257022
Fixes:
4236ce9bf5bf ("event/opdl: add OPDL ring infrastructure library")
Signed-off-by: Liang Ma <liang.j.ma@intel.com>
uint32_t i = 0, offset;
uint8_t *entries_offset = (uint8_t *)entries;
+ if (seq == NULL) {
+ PMD_DRV_LOG(ERR, "Invalid seq PTR");
+ return 0;
+ }
offset = opdl_first_entry_id(*seq, s->nb_instance, s->instance_id);
num_entries = offset + (s->nb_instance * num_entries);
entries_offset += t->slot_size;
i++;
}
- if (seq != NULL)
- *seq = old_head;
+
+ *seq = old_head;
return i;
}