OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/password_manager/native_backend_kwallet_x.h" | 5 #include "chrome/browser/password_manager/native_backend_kwallet_x.h" |
6 | 6 |
7 #include <vector> | 7 #include <vector> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/logging.h" | 10 #include "base/logging.h" |
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
179 session_bus_->GetObjectProxy(kKLauncherServiceName, | 179 session_bus_->GetObjectProxy(kKLauncherServiceName, |
180 dbus::ObjectPath(kKLauncherPath)); | 180 dbus::ObjectPath(kKLauncherPath)); |
181 | 181 |
182 dbus::MethodCall method_call(kKLauncherInterface, | 182 dbus::MethodCall method_call(kKLauncherInterface, |
183 "start_service_by_desktop_name"); | 183 "start_service_by_desktop_name"); |
184 dbus::MessageWriter builder(&method_call); | 184 dbus::MessageWriter builder(&method_call); |
185 std::vector<std::string> empty; | 185 std::vector<std::string> empty; |
186 builder.AppendString("kwalletd"); // serviceName | 186 builder.AppendString("kwalletd"); // serviceName |
187 builder.AppendArrayOfStrings(empty); // urls | 187 builder.AppendArrayOfStrings(empty); // urls |
188 builder.AppendArrayOfStrings(empty); // envs | 188 builder.AppendArrayOfStrings(empty); // envs |
189 builder.AppendString(""); // startup_id | 189 builder.AppendString(std::string()); // startup_id |
190 builder.AppendBool(false); // blind | 190 builder.AppendBool(false); // blind |
191 scoped_ptr<dbus::Response> response( | 191 scoped_ptr<dbus::Response> response( |
192 klauncher->CallMethodAndBlock( | 192 klauncher->CallMethodAndBlock( |
193 &method_call, dbus::ObjectProxy::TIMEOUT_USE_DEFAULT)); | 193 &method_call, dbus::ObjectProxy::TIMEOUT_USE_DEFAULT)); |
194 if (!response.get()) { | 194 if (!response.get()) { |
195 LOG(ERROR) << "Error contacting klauncher to start kwalletd"; | 195 LOG(ERROR) << "Error contacting klauncher to start kwalletd"; |
196 return false; | 196 return false; |
197 } | 197 } |
198 dbus::MessageReader reader(response.get()); | 198 dbus::MessageReader reader(response.get()); |
199 int32_t ret = -1; | 199 int32_t ret = -1; |
(...skipping 761 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
961 // Each other profile must be able to migrate the shared data as well, | 961 // Each other profile must be able to migrate the shared data as well, |
962 // so we must leave it alone. After a few releases, we'll add code to | 962 // so we must leave it alone. After a few releases, we'll add code to |
963 // delete them, and eventually remove this migration code. | 963 // delete them, and eventually remove this migration code. |
964 // TODO(mdm): follow through with the plan above. | 964 // TODO(mdm): follow through with the plan above. |
965 PasswordStoreX::SetPasswordsUseLocalProfileId(prefs_); | 965 PasswordStoreX::SetPasswordsUseLocalProfileId(prefs_); |
966 } else { | 966 } else { |
967 // We failed to migrate for some reason. Use the old folder name. | 967 // We failed to migrate for some reason. Use the old folder name. |
968 folder_name_ = kKWalletFolder; | 968 folder_name_ = kKWalletFolder; |
969 } | 969 } |
970 } | 970 } |
OLD | NEW |