From 1abcdd7f507cea6472f8dc762df651c745a750f4 Mon Sep 17 00:00:00 2001 From: jp9000 Date: Fri, 12 Sep 2014 00:46:24 -0700 Subject: [PATCH] WinHandle: Do not close handle on operator & This is not a com pointer; it should not release/close the handle when an & operator is used, it should only return the handle value. Clearing is only used on assignment. --- libobs/util/windows/WinHandle.hpp | 2 -- 1 file changed, 2 deletions(-) diff --git a/libobs/util/windows/WinHandle.hpp b/libobs/util/windows/WinHandle.hpp index 7112e753c..708c07b9b 100644 --- a/libobs/util/windows/WinHandle.hpp +++ b/libobs/util/windows/WinHandle.hpp @@ -44,8 +44,6 @@ public: inline HANDLE* operator&() { - Clear(); - handle = NULL; return &handle; }