[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:14:55 UTC 2009


The following commit has been merged in the debian/unstable branch:
commit 957a1b3b0eda6fee13293e8fb5896a813b2bc31a
Author: mjs <mjs at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Sun Dec 15 00:37:56 2002 +0000

            Reviewed by Dave.
    
    	- fix toString() conversion for numbers less than 1. Negative
    	exponents are still wrong though (things like 1E-34).
    
            * kjs/ustring.cpp:
    	(UString::from): Don't print empty string for numbers less than 1,
    	and remember to add extra 0s after the decimal for negative
    	decimal positions.
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@3051 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/JavaScriptCore/ChangeLog b/JavaScriptCore/ChangeLog
index 8bc4d43..1c21f03 100644
--- a/JavaScriptCore/ChangeLog
+++ b/JavaScriptCore/ChangeLog
@@ -1,3 +1,15 @@
+2002-12-14  Maciej Stachowiak  <mjs at apple.com>
+
+        Reviewed by Dave.
+
+	- fix toString() conversion for numbers less than 1. Negative
+	exponents are still wrong though (things like 1E-34).
+ 
+        * kjs/ustring.cpp:
+	(UString::from): Don't print empty string for numbers less than 1,
+	and remember to add extra 0s after the decimal for negative
+	decimal positions.
+	
 === Alexander-37u1 ===
 
 === Alexander-36 ===
diff --git a/JavaScriptCore/ChangeLog-2003-10-25 b/JavaScriptCore/ChangeLog-2003-10-25
index 8bc4d43..1c21f03 100644
--- a/JavaScriptCore/ChangeLog-2003-10-25
+++ b/JavaScriptCore/ChangeLog-2003-10-25
@@ -1,3 +1,15 @@
+2002-12-14  Maciej Stachowiak  <mjs at apple.com>
+
+        Reviewed by Dave.
+
+	- fix toString() conversion for numbers less than 1. Negative
+	exponents are still wrong though (things like 1E-34).
+ 
+        * kjs/ustring.cpp:
+	(UString::from): Don't print empty string for numbers less than 1,
+	and remember to add extra 0s after the decimal for negative
+	decimal positions.
+	
 === Alexander-37u1 ===
 
 === Alexander-36 ===
diff --git a/JavaScriptCore/kjs/ustring.cpp b/JavaScriptCore/kjs/ustring.cpp
index 7a39b2e..d9b2464 100644
--- a/JavaScriptCore/kjs/ustring.cpp
+++ b/JavaScriptCore/kjs/ustring.cpp
@@ -346,8 +346,11 @@ UString UString::from(double d)
   }
   
   if (decimalPoint <= 0) {
-    buf[i++] = 0;
+    buf[i++] = '0';
     buf[i++] = '.';
+    for (int j = decimalPoint; j < 0; j++) {
+      buf[i++] = '0';
+    }
     strcpy(buf + i, result);
   } else if (decimalPoint >= length) {
     strcpy(buf + i, result);

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list