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

Side by Side Diff: third_party/WebKit/Source/core/loader/FrameLoader.cpp

Issue 2785873002: Detached FrameLoader should not log snapshot trace events (Closed)
Patch Set: Created 3 years, 8 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights
3 * reserved. 3 * reserved.
4 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) 4 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies)
5 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. 5 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved.
6 * (http://www.torchmobile.com/) 6 * (http://www.torchmobile.com/)
7 * Copyright (C) 2008 Alp Toker <alp@atoker.com> 7 * Copyright (C) 2008 Alp Toker <alp@atoker.com>
8 * Copyright (C) Research In Motion Limited 2009. All rights reserved. 8 * Copyright (C) Research In Motion Limited 2009. All rights reserved.
9 * Copyright (C) 2011 Kris Jordan <krisjordan@gmail.com> 9 * Copyright (C) 2011 Kris Jordan <krisjordan@gmail.com>
10 * Copyright (C) 2011 Google Inc. All rights reserved. 10 * Copyright (C) 2011 Google Inc. All rights reserved.
(...skipping 1867 matching lines...) Expand 10 before | Expand all | Expand 10 after
1878 tracedValue->setString("provisionalDocumentLoaderURL", 1878 tracedValue->setString("provisionalDocumentLoaderURL",
1879 m_provisionalDocumentLoader 1879 m_provisionalDocumentLoader
1880 ? m_provisionalDocumentLoader->url() 1880 ? m_provisionalDocumentLoader->url()
1881 : String()); 1881 : String());
1882 tracedValue->setString("documentLoaderURL", 1882 tracedValue->setString("documentLoaderURL",
1883 m_documentLoader ? m_documentLoader->url() : String()); 1883 m_documentLoader ? m_documentLoader->url() : String());
1884 return tracedValue; 1884 return tracedValue;
1885 } 1885 }
1886 1886
1887 inline void FrameLoader::takeObjectSnapshot() const { 1887 inline void FrameLoader::takeObjectSnapshot() const {
1888 if (!m_progressTracker) {
kouhei (in TOK) 2017/03/30 04:49:22 Would you m_frame = nullptr in ::detach() and chec
Kunihiko Sakamoto 2017/03/30 05:08:58 Hmm, ::clear() uses m_frame after ::detach() (call
Kunihiko Sakamoto 2017/03/30 05:52:22 m_frame = nullptr in clear() didn't work either. H
1889 // We already logged TRACE_EVENT_OBJECT_DELETED_WITH_ID in detach().
1890 return;
1891 }
1888 TRACE_EVENT_OBJECT_SNAPSHOT_WITH_ID("loading", "FrameLoader", this, 1892 TRACE_EVENT_OBJECT_SNAPSHOT_WITH_ID("loading", "FrameLoader", this,
1889 toTracedValue()); 1893 toTracedValue());
1890 } 1894 }
1891 1895
1892 DocumentLoader* FrameLoader::createDocumentLoader( 1896 DocumentLoader* FrameLoader::createDocumentLoader(
1893 const ResourceRequest& request, 1897 const ResourceRequest& request,
1894 const FrameLoadRequest& frameLoadRequest, 1898 const FrameLoadRequest& frameLoadRequest,
1895 FrameLoadType loadType, 1899 FrameLoadType loadType,
1896 NavigationType navigationType) { 1900 NavigationType navigationType) {
1897 DocumentLoader* loader = client()->createDocumentLoader( 1901 DocumentLoader* loader = client()->createDocumentLoader(
1898 m_frame, request, frameLoadRequest.substituteData().isValid() 1902 m_frame, request, frameLoadRequest.substituteData().isValid()
1899 ? frameLoadRequest.substituteData() 1903 ? frameLoadRequest.substituteData()
1900 : defaultSubstituteDataForURL(request.url()), 1904 : defaultSubstituteDataForURL(request.url()),
1901 frameLoadRequest.clientRedirect()); 1905 frameLoadRequest.clientRedirect());
1902 1906
1903 loader->setLoadType(loadType); 1907 loader->setLoadType(loadType);
1904 loader->setNavigationType(navigationType); 1908 loader->setNavigationType(navigationType);
1905 loader->setReplacesCurrentHistoryItem(loadType == 1909 loader->setReplacesCurrentHistoryItem(loadType ==
1906 FrameLoadTypeReplaceCurrentItem); 1910 FrameLoadTypeReplaceCurrentItem);
1907 return loader; 1911 return loader;
1908 } 1912 }
1909 1913
1910 } // namespace blink 1914 } // namespace blink
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698