blob: check memory allocation in check_readahead
Change-Id: I80a1b19570aab8145e8d8d2c544ed46576a89e60 Signed-off-by: GangCao <gang.cao@intel.com>
This commit is contained in:
parent
55d8cca428
commit
57986fb884
@ -1916,8 +1916,13 @@ check_readahead(struct spdk_file *file, uint64_t offset)
|
||||
return;
|
||||
}
|
||||
|
||||
BLOBFS_TRACE(file, "offset=%jx\n", offset);
|
||||
args = calloc(1, sizeof(*args));
|
||||
if (args == NULL) {
|
||||
return;
|
||||
}
|
||||
|
||||
BLOBFS_TRACE(file, "offset=%jx\n", offset);
|
||||
|
||||
args->file = file;
|
||||
args->op.readahead.offset = offset;
|
||||
args->op.readahead.cache_buffer = cache_insert_buffer(file, offset);
|
||||
|
Loading…
Reference in New Issue
Block a user