diff options
Diffstat (limited to 'remoting/host/plugin/host_plugin_utils.cc')
-rw-r--r-- | remoting/host/plugin/host_plugin_utils.cc | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/remoting/host/plugin/host_plugin_utils.cc b/remoting/host/plugin/host_plugin_utils.cc index c1682c4b..d8061cf 100644 --- a/remoting/host/plugin/host_plugin_utils.cc +++ b/remoting/host/plugin/host_plugin_utils.cc @@ -1,4 +1,4 @@ -// Copyright (c) 2011 The Chromium Authors. All rights reserved. +// Copyright (c) 2012 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. @@ -47,6 +47,11 @@ ScopedRefNPObject::ScopedRefNPObject(NPObject* object) *this = object; } +ScopedRefNPObject::ScopedRefNPObject(const ScopedRefNPObject& object) + : object_(NULL) { + *this = object; +} + ScopedRefNPObject::~ScopedRefNPObject() { *this = NULL; } @@ -62,4 +67,9 @@ ScopedRefNPObject& ScopedRefNPObject::operator=(NPObject* object) { return *this; } +ScopedRefNPObject& ScopedRefNPObject::operator=( + const ScopedRefNPObject& object) { + return *this = object.get(); +} + } // namespace remoting |