提交 2a5d14e2 编写于 作者: J John Ferlan 提交者: Eric Blake

uml: Avoid resource leak of event in umlInofityEvent

If there was more than one inotify_event found in the read/while loop,
then only the last event found would have been queued.
上级 8f7b75fb
...@@ -410,11 +410,13 @@ reread: ...@@ -410,11 +410,13 @@ reread:
} }
if (dom) if (dom)
virObjectUnlock(dom); virObjectUnlock(dom);
if (event) {
umlDomainEventQueue(driver, event);
event = NULL;
}
} }
cleanup: cleanup:
if (event)
umlDomainEventQueue(driver, event);
umlDriverUnlock(driver); umlDriverUnlock(driver);
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册