Force LoongArchCPUInfoParser::TotalLogicalCount() to return int on all code paths

This commit is contained in:
Ilya Sorochan 2024-11-19 15:40:46 +03:00
parent 1c0f9d3d4f
commit a04bb579dc

View File

@ -94,15 +94,11 @@ int LoongArchCPUInfoParser::TotalLogicalCount() {
int low, high, found;
std::getline(presentFile, line);
found = sscanf(line.c_str(), "%d-%d", &low, &high);
if (found == 1){
return 1;
}
if (found == 2){
return high - low + 1;
}
}else{
return 1;
}
return 1;
}
#endif