Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1079)

Unified Diff: remoting/host/pairing_registry_delegate_linux.cc

Issue 2051663003: base::ListValue::Append cleanup: pass unique_ptr instead of the released pointer. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: remoting/host/pairing_registry_delegate_linux.cc
diff --git a/remoting/host/pairing_registry_delegate_linux.cc b/remoting/host/pairing_registry_delegate_linux.cc
index f6ad1c52e09d5e92b0c5f850cf90a3ec2e7fad03..53eaf77c539cfea935d32bcc5f703a2d7fa828de 100644
--- a/remoting/host/pairing_registry_delegate_linux.cc
+++ b/remoting/host/pairing_registry_delegate_linux.cc
@@ -4,6 +4,8 @@
#include "remoting/host/pairing_registry_delegate_linux.h"
+#include <utility>
+
#include "base/bind.h"
#include "base/files/file_enumerator.h"
#include "base/files/file_util.h"
@@ -58,7 +60,7 @@ std::unique_ptr<base::ListValue> PairingRegistryDelegateLinux::LoadAll() {
continue;
}
- pairings->Append(pairing_json.release());
+ pairings->Append(std::move(pairing_json));
}
return pairings;

Powered by Google App Engine
This is Rietveld 408576698