| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 // | 4 // |
| 5 #include "chrome_frame/html_utils.h" | 5 #include "chrome_frame/html_utils.h" |
| 6 | 6 |
| 7 #include <atlbase.h> | 7 #include <atlbase.h> |
| 8 #include <urlmon.h> | 8 #include <urlmon.h> |
| 9 | 9 |
| 10 #include "base/string_util.h" | 10 #include "base/string_util.h" |
| 11 #include "base/string_tokenizer.h" | 11 #include "base/string_tokenizer.h" |
| 12 #include "base/stringprintf.h" | 12 #include "base/stringprintf.h" |
| 13 #include "chrome/common/chrome_version_info.h" | 13 #include "chrome/common/chrome_version_info.h" |
| 14 #include "chrome_frame/utils.h" | 14 #include "chrome_frame/utils.h" |
| 15 #include "net/base/net_util.h" | 15 #include "net/base/net_util.h" |
| 16 #include "webkit/glue/user_agent.h" | 16 #include "webkit/user_agent/user_agent_util.h" |
| 17 | 17 |
| 18 const wchar_t kQuotes[] = L"\"'"; | 18 const wchar_t kQuotes[] = L"\"'"; |
| 19 const char kXFrameOptionsHeader[] = "X-Frame-Options"; | 19 const char kXFrameOptionsHeader[] = "X-Frame-Options"; |
| 20 const char kXFrameOptionsValueAllowAll[] = "allowall"; | 20 const char kXFrameOptionsValueAllowAll[] = "allowall"; |
| 21 | 21 |
| 22 HTMLScanner::StringRange::StringRange() { | 22 HTMLScanner::StringRange::StringRange() { |
| 23 } | 23 } |
| 24 | 24 |
| 25 HTMLScanner::StringRange::StringRange(StrPos start, StrPos end) | 25 HTMLScanner::StringRange::StringRange(StrPos start, StrPos end) |
| 26 : start_(start), end_(end) { | 26 : start_(start), end_(end) { |
| (...skipping 439 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 466 const std::string& headers) { | 466 const std::string& headers) { |
| 467 net::HttpUtil::HeadersIterator it(headers.begin(), headers.end(), "\r\n"); | 467 net::HttpUtil::HeadersIterator it(headers.begin(), headers.end(), "\r\n"); |
| 468 while (it.GetNext()) { | 468 while (it.GetNext()) { |
| 469 if (!lstrcmpiA(it.name().c_str(), header.c_str())) | 469 if (!lstrcmpiA(it.name().c_str(), header.c_str())) |
| 470 return std::string(it.values_begin(), it.values_end()); | 470 return std::string(it.values_begin(), it.values_end()); |
| 471 } | 471 } |
| 472 return std::string(); | 472 return std::string(); |
| 473 } | 473 } |
| 474 | 474 |
| 475 } // namespace http_utils | 475 } // namespace http_utils |
| OLD | NEW |