提交 a3e5344c 编写于 作者: J James Park 提交者: jp9000

libobs: Fix move assignment operator for ComPtr

We can't compare addresses of ComPtr for self-reference directly because
the address-of operator is overloaded, causing a compiler error. This
fix more or less matches the WRL implementation.
上级 a0ead6f9
......@@ -68,7 +68,7 @@ public:
inline ComPtr<T> &operator=(ComPtr<T> &&c)
{
if (this != &c) {
if (&ptr != &c.ptr) {
Kill();
ptr = c.ptr;
c.ptr = nullptr;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册