diff --git a/DirectXTex/scoped.h b/DirectXTex/scoped.h index 23b3485..c81ee30 100644 --- a/DirectXTex/scoped.h +++ b/DirectXTex/scoped.h @@ -65,13 +65,13 @@ public: operator bool() const { return (_pointer != nullptr); } - T& operator= (_In_opt_ T* other) + ScopedObject& operator= (_In_opt_ T* other) { if ( _pointer != other ) { if ( _pointer) { _pointer->Release(); } _pointer = other; - if ( other ) { other->AddRef() }; + if ( other ) { other->AddRef(); }; } return *this; }