[SWDEV-524528] Nullptr check correction for TestErrCntRead (#38)
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com>
[ROCm/rocm_smi_lib commit: 91f30c5756]
This commit is contained in:
@@ -659,8 +659,6 @@ rsmi_dev_ecc_count_get(uint32_t dv_ind, rsmi_gpu_block_t block,
|
|||||||
TRY
|
TRY
|
||||||
ss << __PRETTY_FUNCTION__ << "| ======= start =======";
|
ss << __PRETTY_FUNCTION__ << "| ======= start =======";
|
||||||
LOG_TRACE(ss);
|
LOG_TRACE(ss);
|
||||||
CHK_SUPPORT_VAR(ec, block)
|
|
||||||
|
|
||||||
|
|
||||||
amd::smi::DevInfoTypes type;
|
amd::smi::DevInfoTypes type;
|
||||||
switch (block) {
|
switch (block) {
|
||||||
@@ -720,6 +718,10 @@ rsmi_dev_ecc_count_get(uint32_t dv_ind, rsmi_gpu_block_t block,
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (ec == nullptr) {
|
||||||
|
return RSMI_STATUS_INVALID_ARGS;
|
||||||
|
}
|
||||||
|
|
||||||
std::string junk;
|
std::string junk;
|
||||||
std::istringstream fs1(val_vec[0]);
|
std::istringstream fs1(val_vec[0]);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user