make copy constructor and a assignment operator private to avoid misuse of helper class scope guard
Signed-off-by: Kim Kulling <kim.kulling@googlemail.com>
This commit is contained in:
@@ -90,6 +90,10 @@ struct ScopeGuard
|
||||
}
|
||||
|
||||
private:
|
||||
// no copying allowed.
|
||||
ScopeGuard( const ScopeGuard & );
|
||||
ScopeGuard &operator = ( const ScopeGuard & );
|
||||
|
||||
T* obj;
|
||||
bool mdismiss;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user