提交 40ebbf72 编写于 作者: M Michal Privoznik

qemuDomainCreateNamespace: s/unlink/rmdir/

If something goes wrong in this function we try a rollback. That
is unlink all the directories we created earlier. For some weird
reason unlink() was called instead of rmdir().
Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
上级 095f042e
......@@ -7467,9 +7467,9 @@ qemuDomainCreateNamespace(virQEMUDriverPtr driver,
cleanup:
if (ret < 0) {
if (devPath)
unlink(devPath);
rmdir(devPath);
for (i = 0; i < ndevMountsSavePath; i++)
unlink(devMountsSavePath[i]);
rmdir(devMountsSavePath[i]);
}
virStringListFreeCount(devMountsSavePath, ndevMountsSavePath);
VIR_FREE(devPath);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册