Skip to content

Commit

Permalink
Add assert of CacheDisk is not nullptr (#10704)
Browse files Browse the repository at this point in the history
  • Loading branch information
masaori335 authored Nov 1, 2023
1 parent d96ecb3 commit 5088bba
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/iocore/cache/Cache.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1266,7 +1266,8 @@ cplist_init()
{
cp_list_len = 0;
for (int i = 0; i < gndisks; i++) {
CacheDisk *d = gdisks[i];
CacheDisk *d = gdisks[i];
ink_assert(d != nullptr);
DiskStripe **dp = d->disk_vols;
for (unsigned int j = 0; j < d->header->num_volumes; j++) {
ink_assert(dp[j]->dpb_queue.head);
Expand Down

0 comments on commit 5088bba

Please sign in to comment.