OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Neither the name of Google Inc. nor the names of its | 10 * * Neither the name of Google Inc. nor the names of its |
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
95 | 95 |
96 inline bool ContextFeatures::isEnabled(Document* document, FeatureType type, boo
l defaultValue) const | 96 inline bool ContextFeatures::isEnabled(Document* document, FeatureType type, boo
l defaultValue) const |
97 { | 97 { |
98 if (!m_client) | 98 if (!m_client) |
99 return defaultValue; | 99 return defaultValue; |
100 return m_client->isEnabled(document, type, defaultValue); | 100 return m_client->isEnabled(document, type, defaultValue); |
101 } | 101 } |
102 | 102 |
103 inline void ContextFeatures::urlDidChange(Document* document) | 103 inline void ContextFeatures::urlDidChange(Document* document) |
104 { | 104 { |
105 if (m_client) | 105 // FIXME: The original code, commented out below, is obviously |
106 return; | 106 // wrong, but the seemingly correct fix of negating the test to |
107 m_client->urlDidChange(document); | 107 // the more logical 'if (!m_client)' crashes the renderer. |
| 108 // See issue 294180 |
| 109 // |
| 110 // if (m_client) |
| 111 // return; |
| 112 // m_client->urlDidChange(document); |
108 } | 113 } |
109 | 114 |
110 } // namespace WebCore | 115 } // namespace WebCore |
111 | 116 |
112 #endif // ContextFeatures_h | 117 #endif // ContextFeatures_h |
OLD | NEW |