From dd91e772430dc294e3bf478c119ef8d43c0a3358 Mon Sep 17 00:00:00 2001 From: Simon Hausmann Date: Mon, 12 Mar 2012 14:11:15 +0100 Subject: Imported WebKit commit 3db4eb1820ac8fb03065d7ea73a4d9db1e8fea1a (http://svn.webkit.org/repository/webkit/trunk@110422) This includes build fixes for the latest qtbase/qtdeclarative as well as the final QML2 API. --- Source/JavaScriptCore/wtf/ArrayBufferView.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'Source/JavaScriptCore/wtf/ArrayBufferView.h') diff --git a/Source/JavaScriptCore/wtf/ArrayBufferView.h b/Source/JavaScriptCore/wtf/ArrayBufferView.h index 24ce25a5e..f314dd56c 100644 --- a/Source/JavaScriptCore/wtf/ArrayBufferView.h +++ b/Source/JavaScriptCore/wtf/ArrayBufferView.h @@ -26,7 +26,7 @@ #ifndef ArrayBufferView_h #define ArrayBufferView_h -#include "ArrayBuffer.h" +#include #include #include @@ -36,7 +36,7 @@ namespace WTF { -class ArrayBufferView : public RefCounted { +class WTF_EXPORT_PRIVATE_RTTI ArrayBufferView : public RefCounted { public: virtual bool isByteArray() const { return false; } virtual bool isUnsignedByteArray() const { return false; } @@ -186,6 +186,8 @@ void ArrayBufferView::calculateOffsetAndLength(int start, int end, unsigned arra end += arraySize; if (end < 0) end = 0; + if (static_cast(end) > arraySize) + end = arraySize; if (end < start) end = start; *offset = static_cast(start); -- cgit v1.2.1