提交 7489a9c3 编写于 作者: J John Ferlan 提交者: Peter Krempa

nodeinfo: Use sa_assert() instead of Coverity error tag

上级 abbec81b
......@@ -1124,8 +1124,8 @@ nodeSetMemoryParameterValue(virTypedParameterPtr param)
int ret = -1;
int rc = -1;
/* coverity[returned_null] */
char *field = strchr(param->field, '_');
sa_assert(field);
field++;
if (virAsprintf(&path, "%s/%s",
SYSFS_MEMORY_SHARED_PATH, field) < 0) {
......@@ -1162,8 +1162,8 @@ nodeMemoryParametersIsAllSupported(virTypedParameterPtr params,
for (i = 0; i < nparams; i++) {
virTypedParameterPtr param = &params[i];
/* coverity[returned_null] */
char *field = strchr(param->field, '_');
sa_assert(field);
field++;
if (virAsprintf(&path, "%s/%s",
SYSFS_MEMORY_SHARED_PATH, field) < 0) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册