[webkit-changes] cvs commit: JavaScriptCore/kjs value.cpp
Adele
adele at opensource.apple.com
Thu Nov 17 14:44:02 PST 2005
adele 05/11/17 14:44:01
Modified: . Tag: Safari-2-0-branch ChangeLog
kjs Tag: Safari-2-0-branch value.cpp
Log:
Fix by Darin, reviewed by me.
fix for <rdar://problem/3885811> Some values used with setAttribute() cause the attribute to be removed (null strings vs. empty strings) (4059)
Changed the constructors to return the emtpy string if the string is null.
* kjs/value.cpp:
(Value::Value):
(String::String):
Revision Changes Path
No revision
No revision
1.677.6.59 +12 -0 JavaScriptCore/ChangeLog
Index: ChangeLog
===================================================================
RCS file: /cvs/root/JavaScriptCore/ChangeLog,v
retrieving revision 1.677.6.58
retrieving revision 1.677.6.59
diff -u -r1.677.6.58 -r1.677.6.59
--- ChangeLog 17 Nov 2005 00:30:48 -0000 1.677.6.58
+++ ChangeLog 17 Nov 2005 22:44:00 -0000 1.677.6.59
@@ -1,3 +1,15 @@
+2005-11-17 Adele Peterson <adele at apple.com>
+
+ Fix by Darin, reviewed by me.
+
+ fix for <rdar://problem/3885811> Some values used with setAttribute() cause the attribute to be removed (null strings vs. empty strings) (4059)
+
+ Changed the constructors to return the emtpy string if the string is null.
+
+ * kjs/value.cpp:
+ (Value::Value):
+ (String::String):
+
=== JavaScriptCore-417.7 ===
2005-11-16 Timothy Hatcher <timothy at apple.com>
No revision
No revision
1.23.10.2 +3 -3 JavaScriptCore/kjs/value.cpp
Index: value.cpp
===================================================================
RCS file: /cvs/root/JavaScriptCore/kjs/value.cpp,v
retrieving revision 1.23.10.1
retrieving revision 1.23.10.2
diff -u -r1.23.10.1 -r1.23.10.2
--- value.cpp 22 Jul 2005 03:09:33 -0000 1.23.10.1
+++ value.cpp 17 Nov 2005 22:44:01 -0000 1.23.10.2
@@ -265,9 +265,9 @@
Value::Value(unsigned long l)
: rep(SimpleNumber::fits(l) ? SimpleNumber::make(l) : new NumberImp(static_cast<double>(l))) { }
-Value::Value(const char *s) : rep(new StringImp(s)) { }
+Value::Value(const char *s) : rep(new StringImp(s ? s : "")) { }
-Value::Value(const UString &s) : rep(new StringImp(s)) { }
+Value::Value(const UString &s) : rep(new StringImp(s.isNull() ? "" : s)) { }
// ------------------------------ Undefined ------------------------------------
@@ -320,7 +320,7 @@
// ------------------------------ String ---------------------------------------
-String::String(const UString &s) : Value(new StringImp(s))
+String::String(const UString &s) : Value(new StringImp(s.isNull() ? "" : s))
{
}
More information about the webkit-changes
mailing list