Merge pull request #661 from mmichal10/check-id-on-actiavte

Verify cache id duing the activate
This commit is contained in:
Robert Baldyga 2022-02-18 15:41:01 +01:00 committed by GitHub
commit b65ca6233b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -2416,6 +2416,13 @@ static void _ocf_mngt_activate_check_superblock(ocf_pipeline_t pipeline,
-OCF_ERR_CACHE_LINE_SIZE_MISMATCH);
}
if (env_strncmp(cache->conf_meta->name, OCF_CACHE_NAME_SIZE,
cache->name, OCF_CACHE_NAME_SIZE)) {
ocf_cache_log(cache, log_err, "Failed to activate standby instance: "
"cache name mismtach\n");
OCF_PL_FINISH_RET(context->pipeline, -OCF_ERR_CACHE_NAME_MISMATCH);
}
ocf_pipeline_next(pipeline);
}