提交 79052a76 编写于 作者: E Eric Blake

storage: plug iscsi memory leak

Detected by Coverity.  virStoragePoolSourceFree does not free the
actual passed-in pointer.  A bigger patch would be to rename it
virStoragePoolSourceClear to match behavior, or even split it into
two functions depending on needed behavior; but this is the minimal
fix to the one location out of eight that leaked memory.

* src/storage/storage_backend_iscsi.c
(virStorageBackendISCSIFindPoolSources): Free memory.
上级 69d044c0
......@@ -611,6 +611,7 @@ cleanup:
VIR_FREE(targets);
VIR_FREE(portal);
virStoragePoolSourceFree(source);
VIR_FREE(source);
return ret;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册