Update To 11.40.268.0
[platform/framework/web/crosswalk.git] / src / remoting / host / setup / daemon_controller_delegate_win.cc
index 9ed446e..36f55e5 100644 (file)
@@ -173,13 +173,13 @@ scoped_ptr<base::DictionaryValue> DaemonControllerDelegateWin::GetConfig() {
   // Configure and start the Daemon Controller if it is installed already.
   HRESULT hr = ActivateController();
   if (FAILED(hr))
-    return scoped_ptr<base::DictionaryValue>();
+    return nullptr;
 
   // Get the host configuration.
   ScopedBstr host_config;
   hr = control_->GetConfig(host_config.Receive());
   if (FAILED(hr))
-    return scoped_ptr<base::DictionaryValue>();
+    return nullptr;
 
   // Parse the string into a dictionary.
   base::string16 file_content(
@@ -188,11 +188,10 @@ scoped_ptr<base::DictionaryValue> DaemonControllerDelegateWin::GetConfig() {
       base::JSONReader::Read(base::UTF16ToUTF8(file_content),
           base::JSON_ALLOW_TRAILING_COMMAS));
 
-  if (!config || config->GetType() != base::Value::TYPE_DICTIONARY)
-    return scoped_ptr<base::DictionaryValue>();
+  if (!config || !config->IsType(base::Value::TYPE_DICTIONARY))
+    return nullptr;
 
-  return scoped_ptr<base::DictionaryValue>(
-      static_cast<base::DictionaryValue*>(config.release()));
+  return make_scoped_ptr(static_cast<base::DictionaryValue*>(config.release()));
 }
 
 void DaemonControllerDelegateWin::InstallHost(