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

Side by Side Diff: Source/core/loader/DocumentLoader.cpp

Issue 1124153003: [Oilpan] [Reland] Migrate classes under core/fetch to Oilpan heap (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Work for comment Created 5 years, 5 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2007, 2008 Apple Inc. All rights reserved.
3 * Copyright (C) 2011 Google Inc. All rights reserved. 3 * Copyright (C) 2011 Google Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 8 *
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 584 matching lines...) Expand 10 before | Expand all | Expand 10 after
595 // It never makes sense to have a document loader that is detached from its 595 // It never makes sense to have a document loader that is detached from its
596 // frame have any loads active, so go ahead and kill all the loads. 596 // frame have any loads active, so go ahead and kill all the loads.
597 stopLoading(); 597 stopLoading();
598 598
599 // If that load cancellation triggered another detach, leave. 599 // If that load cancellation triggered another detach, leave.
600 // (fast/frames/detach-frame-nested-no-crash.html is an example of this.) 600 // (fast/frames/detach-frame-nested-no-crash.html is an example of this.)
601 if (!m_frame) 601 if (!m_frame)
602 return; 602 return;
603 603
604 m_fetcher->clearContext(); 604 m_fetcher->clearContext();
605
605 m_applicationCacheHost->detachFromDocumentLoader(); 606 m_applicationCacheHost->detachFromDocumentLoader();
606 m_applicationCacheHost.clear(); 607 m_applicationCacheHost.clear();
607 WeakIdentifierMap<DocumentLoader>::notifyObjectDestroyed(this); 608 WeakIdentifierMap<DocumentLoader>::notifyObjectDestroyed(this);
608 clearMainResourceHandle(); 609 clearMainResourceHandle();
609 m_frame = nullptr; 610 m_frame = nullptr;
610 } 611 }
611 612
612 void DocumentLoader::clearMainResourceLoader() 613 void DocumentLoader::clearMainResourceLoader()
613 { 614 {
614 m_loadingMainResource = false; 615 m_loadingMainResource = false;
(...skipping 206 matching lines...) Expand 10 before | Expand all | Expand 10 after
821 { 822 {
822 m_writer = createWriterFor(ownerDocument, init, mimeType(), m_writer ? m_wri ter->encoding() : emptyAtom, true, ForceSynchronousParsing); 823 m_writer = createWriterFor(ownerDocument, init, mimeType(), m_writer ? m_wri ter->encoding() : emptyAtom, true, ForceSynchronousParsing);
823 if (!source.isNull()) 824 if (!source.isNull())
824 m_writer->appendReplacingData(source); 825 m_writer->appendReplacingData(source);
825 endWriting(m_writer.get()); 826 endWriting(m_writer.get());
826 } 827 }
827 828
828 DEFINE_WEAK_IDENTIFIER_MAP(DocumentLoader); 829 DEFINE_WEAK_IDENTIFIER_MAP(DocumentLoader);
829 830
830 } // namespace blink 831 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698