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

Unified Diff: net/dns/dns_query.cc

Issue 1352233002: Returning scoped_ptr<> instead of raw pointer in DnsQuery::CloneWithNewId (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 3 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
« no previous file with comments | « net/dns/dns_query.h ('k') | net/dns/dns_query_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/dns/dns_query.cc
diff --git a/net/dns/dns_query.cc b/net/dns/dns_query.cc
index 530508a61de1b3f051e5f7139aeef16ca3cce0bd..f418162df544fea044d895911e89525df247b59e 100644
--- a/net/dns/dns_query.cc
+++ b/net/dns/dns_query.cc
@@ -43,8 +43,8 @@ DnsQuery::DnsQuery(uint16 id, const base::StringPiece& qname, uint16 qtype)
DnsQuery::~DnsQuery() {
}
-DnsQuery* DnsQuery::CloneWithNewId(uint16 id) const {
- return new DnsQuery(*this, id);
+scoped_ptr<DnsQuery> DnsQuery::CloneWithNewId(uint16 id) const {
+ return make_scoped_ptr(new DnsQuery(*this, id));
}
uint16 DnsQuery::id() const {
« no previous file with comments | « net/dns/dns_query.h ('k') | net/dns/dns_query_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698