[SCM] WebKit Debian packaging branch, debian/unstable, updated. debian/1.1.15-1-40151-g37bb677
mjs
mjs at 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Sat Sep 26 07:50:34 UTC 2009
The following commit has been merged in the debian/unstable branch:
commit dbdd2d1b8f65a53a9fee7c1fa6c3782f8e1dfc0f
Author: mjs <mjs at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Thu Aug 7 19:10:01 2003 +0000
Reviewed by Darin.
- fixed 3366975 - repro hang in KJS::Value::Value entering text at eil.com
* kjs/string_object.cpp:
(StringProtoFuncImp::call): When doing a match against a regexp
with the global flag set, make sure to return null rather than an
empty array when there is no match. This is what other browsers do.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@4783 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/JavaScriptCore/ChangeLog b/JavaScriptCore/ChangeLog
index f39f8d4..0ac331c 100644
--- a/JavaScriptCore/ChangeLog
+++ b/JavaScriptCore/ChangeLog
@@ -1,3 +1,14 @@
+2003-08-07 Maciej Stachowiak <mjs at apple.com>
+
+ Reviewed by Darin.
+
+ - fixed 3366975 - repro hang in KJS::Value::Value entering text at eil.com
+
+ * kjs/string_object.cpp:
+ (StringProtoFuncImp::call): When doing a match against a regexp
+ with the global flag set, make sure to return null rather than an
+ empty array when there is no match. This is what other browsers do.
+
2003-08-05 Maciej Stachowiak <mjs at apple.com>
Reviewed by John.
diff --git a/JavaScriptCore/ChangeLog-2003-10-25 b/JavaScriptCore/ChangeLog-2003-10-25
index f39f8d4..0ac331c 100644
--- a/JavaScriptCore/ChangeLog-2003-10-25
+++ b/JavaScriptCore/ChangeLog-2003-10-25
@@ -1,3 +1,14 @@
+2003-08-07 Maciej Stachowiak <mjs at apple.com>
+
+ Reviewed by Darin.
+
+ - fixed 3366975 - repro hang in KJS::Value::Value entering text at eil.com
+
+ * kjs/string_object.cpp:
+ (StringProtoFuncImp::call): When doing a match against a regexp
+ with the global flag set, make sure to return null rather than an
+ empty array when there is no match. This is what other browsers do.
+
2003-08-05 Maciej Stachowiak <mjs at apple.com>
Reviewed by John.
diff --git a/JavaScriptCore/kjs/string_object.cpp b/JavaScriptCore/kjs/string_object.cpp
index 69db249..e1bd909 100644
--- a/JavaScriptCore/kjs/string_object.cpp
+++ b/JavaScriptCore/kjs/string_object.cpp
@@ -272,7 +272,14 @@ Value StringProtoFuncImp::call(ExecState *exec, Object &thisObj, const List &arg
}
if (imp)
imp->put(exec, "lastIndex", Number(lastIndex), DontDelete|DontEnum);
- result = exec->interpreter()->builtinArray().construct(exec, list);
+ if (list.isEmpty()) {
+ // if there are no matches at all, it's important to return
+ // Null instead of an empty array, because this matches
+ // other browsers and because Null is a false value.
+ result = Null();
+ } else {
+ result = exec->interpreter()->builtinArray().construct(exec, list);
+ }
}
}
delete tmpReg;
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list