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

Side by Side Diff: Source/core/fetch/Resource.cpp

Issue 199733008: Revert of HTML Imports: Send credentials for same origin requests (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 9 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 | Annotate | Revision Log
« no previous file with comments | « Source/core/fetch/Resource.h ('k') | Source/core/fetch/ResourceLoader.h » ('j') | 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) 1998 Lars Knoll (knoll@mpi-hd.mpg.de) 2 Copyright (C) 1998 Lars Knoll (knoll@mpi-hd.mpg.de)
3 Copyright (C) 2001 Dirk Mueller (mueller@kde.org) 3 Copyright (C) 2001 Dirk Mueller (mueller@kde.org)
4 Copyright (C) 2002 Waldo Bastian (bastian@kde.org) 4 Copyright (C) 2002 Waldo Bastian (bastian@kde.org)
5 Copyright (C) 2006 Samuel Weinig (sam.weinig@gmail.com) 5 Copyright (C) 2006 Samuel Weinig (sam.weinig@gmail.com)
6 Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserved. 6 Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserved.
7 7
8 This library is free software; you can redistribute it and/or 8 This library is free software; you can redistribute it and/or
9 modify it under the terms of the GNU Library General Public 9 modify it under the terms of the GNU Library General Public
10 License as published by the Free Software Foundation; either 10 License as published by the Free Software Foundation; either
(...skipping 318 matching lines...) Expand 10 before | Expand all | Expand 10 after
329 329
330 if (response.httpStatusCode() == 302 || response.httpStatusCode() == 307) { 330 if (response.httpStatusCode() == 302 || response.httpStatusCode() == 307) {
331 // Default to not cacheable. 331 // Default to not cacheable.
332 // FIXME: Consider allowing these to be cached if they have headers perm itting caching. 332 // FIXME: Consider allowing these to be cached if they have headers perm itting caching.
333 return false; 333 return false;
334 } 334 }
335 335
336 return currentAge(response, responseTimestamp) <= freshnessLifetime(response , responseTimestamp); 336 return currentAge(response, responseTimestamp) <= freshnessLifetime(response , responseTimestamp);
337 } 337 }
338 338
339 const ResourceRequest& Resource::lastResourceRequest()
340 {
341 if (!m_redirectChain.size())
342 return m_resourceRequest;
343 return m_redirectChain.last().m_request;
344 }
345
346 void Resource::willSendRequest(ResourceRequest& request, const ResourceResponse& response) 339 void Resource::willSendRequest(ResourceRequest& request, const ResourceResponse& response)
347 { 340 {
348 m_redirectChain.append(RedirectPair(request, response)); 341 m_redirectChain.append(RedirectPair(request, response));
349 m_requestedFromNetworkingLayer = true; 342 m_requestedFromNetworkingLayer = true;
350 } 343 }
351 344
352 bool Resource::unlock() 345 bool Resource::unlock()
353 { 346 {
354 if (!m_data) 347 if (!m_data)
355 return false; 348 return false;
(...skipping 648 matching lines...) Expand 10 before | Expand all | Expand 10 after
1004 return "Shader"; 997 return "Shader";
1005 case Resource::ImportResource: 998 case Resource::ImportResource:
1006 return "ImportResource"; 999 return "ImportResource";
1007 } 1000 }
1008 ASSERT_NOT_REACHED(); 1001 ASSERT_NOT_REACHED();
1009 return "Unknown"; 1002 return "Unknown";
1010 } 1003 }
1011 #endif // !LOG_DISABLED 1004 #endif // !LOG_DISABLED
1012 1005
1013 } 1006 }
OLDNEW
« no previous file with comments | « Source/core/fetch/Resource.h ('k') | Source/core/fetch/ResourceLoader.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698