Title: [127495] trunk/Source/WebCore
- Revision
- 127495
- Author
- [email protected]
- Date
- 2012-09-04 13:30:09 -0700 (Tue, 04 Sep 2012)
Log Message
ResourceErrorBase needs to identify timeouts
https://bugs.webkit.org/show_bug.cgi?id=95755
Reviewed by Alexey Proskuryakov.
Adding a property to check whether this ResourceError was raised due to a timeout.
This is preparatory work for bug 74802. In order to implement XHR2 timeout functionality,
I need to identify some layers up whether the original network problem has been a timeout.
No new tests, no change in behavior yet.
* platform/network/ResourceErrorBase.cpp:
(WebCore::ResourceErrorBase::copy): Copying new member.
(WebCore::ResourceErrorBase::compare): Comparing new member.
* platform/network/ResourceErrorBase.h:
(WebCore::ResourceErrorBase::setIsTimeout): New setter.
(WebCore::ResourceErrorBase::isTimeout): New getter.
(ResourceErrorBase),
(WebCore::ResourceErrorBase::ResourceErrorBase): Adding m_isTimeout member.
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (127494 => 127495)
--- trunk/Source/WebCore/ChangeLog 2012-09-04 20:25:47 UTC (rev 127494)
+++ trunk/Source/WebCore/ChangeLog 2012-09-04 20:30:09 UTC (rev 127495)
@@ -1,3 +1,25 @@
+2012-09-04 Dominik Röttsches <[email protected]>
+
+ ResourceErrorBase needs to identify timeouts
+ https://bugs.webkit.org/show_bug.cgi?id=95755
+
+ Reviewed by Alexey Proskuryakov.
+
+ Adding a property to check whether this ResourceError was raised due to a timeout.
+ This is preparatory work for bug 74802. In order to implement XHR2 timeout functionality,
+ I need to identify some layers up whether the original network problem has been a timeout.
+
+ No new tests, no change in behavior yet.
+
+ * platform/network/ResourceErrorBase.cpp:
+ (WebCore::ResourceErrorBase::copy): Copying new member.
+ (WebCore::ResourceErrorBase::compare): Comparing new member.
+ * platform/network/ResourceErrorBase.h:
+ (WebCore::ResourceErrorBase::setIsTimeout): New setter.
+ (WebCore::ResourceErrorBase::isTimeout): New getter.
+ (ResourceErrorBase),
+ (WebCore::ResourceErrorBase::ResourceErrorBase): Adding m_isTimeout member.
+
2012-09-04 Tommy Widenflycht <[email protected]>
MediaStream API: Change the MediaStreamTrackList track added/removed signaling
Modified: trunk/Source/WebCore/platform/network/ResourceErrorBase.cpp (127494 => 127495)
--- trunk/Source/WebCore/platform/network/ResourceErrorBase.cpp 2012-09-04 20:25:47 UTC (rev 127494)
+++ trunk/Source/WebCore/platform/network/ResourceErrorBase.cpp 2012-09-04 20:30:09 UTC (rev 127495)
@@ -42,6 +42,7 @@
errorCopy.m_localizedDescription = m_localizedDescription.isolatedCopy();
errorCopy.m_isNull = m_isNull;
errorCopy.m_isCancellation = m_isCancellation;
+ errorCopy.m_isTimeout = m_isTimeout;
platformCopy(errorCopy);
return errorCopy;
}
@@ -74,6 +75,9 @@
if (a.isCancellation() != b.isCancellation())
return false;
+ if (a.isTimeout() != b.isTimeout())
+ return false;
+
return platformCompare(a, b);
}
Modified: trunk/Source/WebCore/platform/network/ResourceErrorBase.h (127494 => 127495)
--- trunk/Source/WebCore/platform/network/ResourceErrorBase.h 2012-09-04 20:25:47 UTC (rev 127494)
+++ trunk/Source/WebCore/platform/network/ResourceErrorBase.h 2012-09-04 20:30:09 UTC (rev 127495)
@@ -49,6 +49,9 @@
void setIsCancellation(bool isCancellation) { m_isCancellation = isCancellation; }
bool isCancellation() const { return m_isCancellation; }
+ void setIsTimeout(bool isTimeout) { m_isTimeout = isTimeout; }
+ bool isTimeout() const { return m_isTimeout; }
+
static bool compare(const ResourceError&, const ResourceError&);
protected:
@@ -56,6 +59,7 @@
: m_errorCode(0)
, m_isNull(true)
, m_isCancellation(false)
+ , m_isTimeout(false)
{
}
@@ -66,6 +70,7 @@
, m_localizedDescription(localizedDescription)
, m_isNull(false)
, m_isCancellation(false)
+ , m_isTimeout(false)
{
}
@@ -86,6 +91,7 @@
String m_localizedDescription;
bool m_isNull;
bool m_isCancellation;
+ bool m_isTimeout;
};
inline bool operator==(const ResourceError& a, const ResourceError& b) { return ResourceErrorBase::compare(a, b); }
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo/webkit-changes