提交 e14d6571 编写于 作者: M Michal Privoznik

conf: Avoid double assignment in virDomainDiskRemove

Although it should be harmless to do:
    disk = disk = def->disks[i]
some not-so-wise compilers may fool around.
Besides, such assignment is useless here.
上级 354e6d4e
...@@ -7124,7 +7124,7 @@ void virDomainDiskInsertPreAlloced(virDomainDefPtr def, ...@@ -7124,7 +7124,7 @@ void virDomainDiskInsertPreAlloced(virDomainDefPtr def,
virDomainDiskDefPtr virDomainDiskDefPtr
virDomainDiskRemove(virDomainDefPtr def, size_t i) virDomainDiskRemove(virDomainDefPtr def, size_t i)
{ {
virDomainDiskDefPtr disk = disk = def->disks[i]; virDomainDiskDefPtr disk = def->disks[i];
if (def->ndisks > 1) { if (def->ndisks > 1) {
memmove(def->disks + i, memmove(def->disks + i,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册