]> git.ipfire.org Git - thirdparty/sqlite.git/commitdiff
Fix a date round-off problem in strftime(). Ticket #2153. (CVS 3575) version_2
authordrh <drh@noemail.net>
Mon, 8 Jan 2007 16:20:28 +0000 (16:20 +0000)
committerdrh <drh@noemail.net>
Mon, 8 Jan 2007 16:20:28 +0000 (16:20 +0000)
FossilOrigin-Name: 47fee16ba9bd8ab2820fe97e89480528114825cd

manifest
manifest.uuid
src/date.c

index 085ae08a0d98751f4b311c417c3f90129995502c..5023a727a85272059c061a0ef48ac82f3cdc0a8e 100644 (file)
--- a/manifest
+++ b/manifest
@@ -1,5 +1,5 @@
-C Fix\sa\sround-off\serror\sin\sthe\s%W\sconversion\sof\sstrftime().\s\sTicket\s#2150.\s(CVS\s3572)
-D 2007-01-08T13:43:38
+C Fix\sa\sdate\sround-off\sproblem\sin\sstrftime().\s\sTicket\s#2153.\s(CVS\s3575)
+D 2007-01-08T16:20:29
 F Makefile.in ab7b0d5118e2da97bac66be8684a1034e3500f5a
 F Makefile.linux-gcc b86a99c493a5bfb402d1d9178dcdc4bd4b32f906
 F README f1de682fbbd94899d50aca13d387d1b3fd3be2dd
@@ -28,7 +28,7 @@ F src/btree.h 41cb3ff6ebc3f6da2d0a074e39ff8c7a2287469f
 F src/btree_rb.c af40501eedd7b673ffd5e02f3a4702c76596d64a
 F src/build.c ee7905531ed592bd68b484f0821fc3cd007e1576
 F src/copy.c 750e13828c3e4a293123e36aaa7cf0f22466248a
-F src/date.c 93658710c630127b5e374d54b606d0d8a66aaa49
+F src/date.c 3f080b6f46c6a96891987b439449e4096c98f925
 F src/delete.c 82001c74882319f94dab5f6b92a27311b31092ae
 F src/encode.c fc8c51f0b61bc803ccdec092e130bebe762b0a2f
 F src/expr.c 6bb3961c0391f2efe788fcfde3c2ff2ff283d5a8
@@ -191,7 +191,7 @@ F www/sqlite.tcl 3c83b08cf9f18aa2d69453ff441a36c40e431604
 F www/tclsqlite.tcl b9271d44dcf147a93c98f8ecf28c927307abd6da
 F www/vdbe.tcl 9b9095d4495f37697fd1935d10e14c6015e80aa1
 F www/whentouse.tcl a8335bce47cc2fddb07f19052cb0cb4d9129a8e4
-P 46b91807f72d65bf24257426bdbee27acff87661
-R ebcd2da4f3e4d0011fad16c712b2fb2e
+P e6a18741a47a4288fa9c4fef93443b19aff20fb9
+R 9093355d0bd0fe007078e08b28b0c272
 U drh
-Z a110c1159d9732f55869863190022fea
+Z 0fe8caf53c43ccf6073cf4d684d73e3a
index e8628ab073131f063d10d0b5b3f5b6bfe8708a04..3ca285fbf9b54edee06f0ae3c60044227d84fa87 100644 (file)
@@ -1 +1 @@
-e6a18741a47a4288fa9c4fef93443b19aff20fb9
\ No newline at end of file
+47fee16ba9bd8ab2820fe97e89480528114825cd
\ No newline at end of file
index 857207248c2570e4ea1a056b0a4e91d2570fd838..9f4f75ade6a37502fd42c8c93ac5a16d6e33760f 100644 (file)
@@ -16,7 +16,7 @@
 ** sqliteRegisterDateTimeFunctions() found at the bottom of the file.
 ** All other code has file scope.
 **
-** $Id: date.c,v 1.16.2.3 2007/01/08 13:43:38 drh Exp $
+** $Id: date.c,v 1.16.2.4 2007/01/08 16:20:29 drh Exp $
 **
 ** NOTES:
 **
@@ -826,7 +826,7 @@ static void strftimeFunc(sqlite_func *context, int argc, const char **argv){
           j += strlen(&z[j]);
           break;
         }
-        case 'S':  sprintf(&z[j],"%02d",(int)(x.s+0.5)); j+=2; break;
+        case 'S':  sprintf(&z[j],"%02d",(int)x.s); j+=2; break;
         case 'w':  z[j++] = (((int)(x.rJD+1.5)) % 7) + '0'; break;
         case 'Y':  sprintf(&z[j],"%04d",x.Y); j+=strlen(&z[j]); break;
         case '%':  z[j++] = '%'; break;