]> git.ipfire.org Git - thirdparty/sqlite.git/commitdiff
Fold in changes submitted by the PHP developers. (CVS 1742)
authordrh <drh@noemail.net>
Sat, 26 Jun 2004 14:40:05 +0000 (14:40 +0000)
committerdrh <drh@noemail.net>
Sat, 26 Jun 2004 14:40:05 +0000 (14:40 +0000)
FossilOrigin-Name: a4a2570822f13ece2174438ef8f8a6175aaa4a6b

manifest
manifest.uuid
src/btree_rb.c
src/build.c
src/main.c
src/os.c
src/table.c
src/vdbeaux.c

index 916e0026282f188c53445ecefdd14cb004cf1da4..c13b46ffec5f600bdb85de7c1d9832fef6caf463 100644 (file)
--- a/manifest
+++ b/manifest
@@ -1,5 +1,5 @@
-C The\sMIN()\saggregate\sfunction\sreturns\sNULL\sif\sany\selement\sin\sthe\sresult\nwas\sNULL.\s\sThis\smakes\sMIN()\sconsistent\swith\sORDER\sBY\swhich\ssorts\sNULL\sfirst.\nTicket\s#777.\s(CVS\s1679)
-D 2004-06-23T21:16:52
+C Fold\sin\schanges\ssubmitted\sby\sthe\sPHP\sdevelopers.\s(CVS\s1742)
+D 2004-06-26T14:40:05
 F Makefile.in ab7b0d5118e2da97bac66be8684a1034e3500f5a
 F Makefile.linux-gcc b86a99c493a5bfb402d1d9178dcdc4bd4b32f906
 F README f1de682fbbd94899d50aca13d387d1b3fd3be2dd
@@ -25,8 +25,8 @@ F src/attach.c 026702566f941bf2bb158a0aaa86bfeb65910aa6
 F src/auth.c f73ae6f7260e3409e9b164a2bb9efffc38054081
 F src/btree.c 08a05b925b348c05d79b9b062b79e50d565678de
 F src/btree.h 41cb3ff6ebc3f6da2d0a074e39ff8c7a2287469f
-F src/btree_rb.c 99feb3ff835106d018a483a1ce403e5cf9c718bc
-F src/build.c 76fbca30081decd6615dee34b48c927ed5063752
+F src/btree_rb.c af40501eedd7b673ffd5e02f3a4702c76596d64a
+F src/build.c cb1ab5ce737ae6b6fe141e256c5e7c524c78ed68
 F src/copy.c 750e13828c3e4a293123e36aaa7cf0f22466248a
 F src/date.c f055419d602bde622c70f831350b6b52f2235de0
 F src/delete.c 82001c74882319f94dab5f6b92a27311b31092ae
@@ -36,9 +36,9 @@ F src/func.c 522d58abf2ec9f93fe3aa08b12611aede570d125
 F src/hash.c 9b56ef3b291e25168f630d5643a4264ec011c70e
 F src/hash.h 3247573ab95b9dd90bcca0307a75d9a16da1ccc7
 F src/insert.c c0485ee2d1b99322894e2d1e0b576fd05ed75616
-F src/main.c 35b6917da56ff1abdfab7fc53d10b815dd4cac16
+F src/main.c 7802ab78b2f2e66750be2192b2c1334c99bc10a5
 F src/md5.c fe4f9c9c6f71dfc26af8da63e4d04489b1430565
-F src/os.c 6a8cf1c1d0551bc8f676496c195232b43e7a9754
+F src/os.c 8cfb27bd84900d542d2f520375aa407cb3ed6aab
 F src/os.h 250a3789be609adfee5c5aa20137ce8683276f24
 F src/pager.c b246986e5ba31b15aa3cf91d3b9ec2e608aceb8e
 F src/pager.h 82332878799280145639a48d88cdb4058925e3f6
@@ -50,7 +50,7 @@ F src/select.c 3833e2b64cc6d249385ee44e13bf49c9ae5b903d
 F src/shell.c 920af040d3a33ea8919c82cee45b424ad841cee0
 F src/sqlite.h.in 35bec264dfb4965bbfeb7e75221f8658f210c30d
 F src/sqliteInt.h 235ce244b62bb26cc9ab394fb7a0724dd4e65c83
-F src/table.c d845cb101b5afc1f7fea083c99e3d2fa7998d895
+F src/table.c eea34544be947e4939ba9e46391d5da998f90b84
 F src/tclsqlite.c 2daaaa41378fbaf167905363197e1d44464b6eb6
 F src/test1.c 4ae20bc125b1a7d7824cccca55d538d81f0b4949
 F src/test2.c 75819b0f2c63c6a0fd6995445881f2eb94036996
@@ -64,7 +64,7 @@ F src/vacuum.c 36a19aa877c696c4ec8b78300c19f4059d2617a7
 F src/vdbe.c 0853ab9983b7adbba8c012bb8b152d8453bf8a97
 F src/vdbe.h ac987945e4dd6f987bca534c6005899f089fc270
 F src/vdbeInt.h b40ff02ce39fd076e6ff3369e19c1bbfe1986682
-F src/vdbeaux.c e2cdd1ab63604a390612c73e26bdd2ef910e9438
+F src/vdbeaux.c 14ff0eb6ed9d5998f927433c91b0a3d13d81f4f6
 F src/where.c b58764861a96bab3f1d294200f9e53519b92c274
 F test/all.test 569a92a8ee88f5300c057cc4a8f50fbbc69a3242
 F test/attach.test ba8261d38da6b6a7d4f78ec543c548c4418582ef
@@ -189,7 +189,7 @@ F www/sqlite.tcl 3c83b08cf9f18aa2d69453ff441a36c40e431604
 F www/tclsqlite.tcl b9271d44dcf147a93c98f8ecf28c927307abd6da
 F www/vdbe.tcl 9b9095d4495f37697fd1935d10e14c6015e80aa1
 F www/whentouse.tcl a8335bce47cc2fddb07f19052cb0cb4d9129a8e4
-P 06bf4c7e41839eb003f3df05a80789a1f2b21b8f
-R dafb0c51f2a215a538fc0976e7da3c17
+P 78ced6e3092d69e7cb77c5c2acff70f3c92e6523
+R 810ffa2137b70c5c615dcdf054631757
 U drh
-Z 693b4009cfcb767a325ed3f699f12e33
+Z 37ce03d1801f0099c401c7f2599ca98b
index eee7045f3fd559c5063296c510f89ab3ce5cc264..5571760b5f19fecb7ce608543ce47662bf13e467 100644 (file)
@@ -1 +1 @@
-78ced6e3092d69e7cb77c5c2acff70f3c92e6523
\ No newline at end of file
+a4a2570822f13ece2174438ef8f8a6175aaa4a6b
\ No newline at end of file
index ea4b3dda756df5ec854f03404872a3f9c13a3e86..7df7077bf2bc50db107230eccfcc8a582f3418d8 100644 (file)
@@ -9,7 +9,7 @@
 **    May you share freely, never taking more than you give.
 **
 *************************************************************************
-** $Id: btree_rb.c,v 1.24 2004/02/29 00:11:31 drh Exp $
+** $Id: btree_rb.c,v 1.24.2.1 2004/06/26 14:40:05 drh Exp $
 **
 ** This file implements an in-core database using Red-Black balanced
 ** binary trees.
@@ -311,7 +311,7 @@ static char *append_node(char * orig, BtRbNode *pNode, int indent)
 static void print_node(BtRbNode *pNode)
 {
     char * str = append_node(0, pNode, 0);
-    printf(str);
+    printf("%s", str);
 
     /* Suppress a warning message about print_node() being unused */
     (void)print_node;
index 3d74322b319c25056ee5e1da0e85262f2022b35e..a4ea39817c9dc5886a8307d3543d7bed97cd34f5 100644 (file)
@@ -23,7 +23,7 @@
 **     ROLLBACK
 **     PRAGMA
 **
-** $Id: build.c,v 1.176 2004/04/23 17:04:44 drh Exp $
+** $Id: build.c,v 1.176.2.1 2004/06/26 14:40:05 drh Exp $
 */
 #include "sqliteInt.h"
 #include <ctype.h>
@@ -1034,7 +1034,7 @@ void sqliteCreateView(
     sEnd.z += sEnd.n;
   }
   sEnd.n = 0;
-  n = ((int)sEnd.z) - (int)pBegin->z;
+  n = sEnd.z - pBegin->z;
   z = pBegin->z;
   while( n>0 && (z[n-1]==';' || isspace(z[n-1])) ){ n--; }
   sEnd.z = &z[n-1];
index 25d0f9b3d1abf95fbdc07bd1db6f25909e09386d..c6904967099ef594447fb5449b1df3cf72074a4e 100644 (file)
@@ -14,7 +14,7 @@
 ** other files are for internal use by SQLite and should not be
 ** accessed by users of the library.
 **
-** $Id: main.c,v 1.164.2.1 2004/06/19 04:23:25 danielk1977 Exp $
+** $Id: main.c,v 1.164.2.2 2004/06/26 14:40:05 drh Exp $
 */
 #include "sqliteInt.h"
 #include "os.h"
@@ -873,7 +873,7 @@ static int sqliteDefaultBusyCallback(
   static const short int totals[] =
      { 0, 1, 3,  8, 18, 33, 53, 78, 103, 128, 178, 228, 287};
 # define NDELAY (sizeof(delays)/sizeof(delays[0]))
-  int timeout = (int)Timeout;
+  int timeout = (int)(long)Timeout;
   int delay, prior;
 
   if( count <= NDELAY ){
@@ -890,7 +890,7 @@ static int sqliteDefaultBusyCallback(
   sqliteOsSleep(delay);
   return 1;
 #else
-  int timeout = (int)Timeout;
+  int timeout = (int)(long)Timeout;
   if( (count+1)*1000 > timeout ){
     return 0;
   }
@@ -943,7 +943,7 @@ void sqlite_progress_handler(
 */
 void sqlite_busy_timeout(sqlite *db, int ms){
   if( ms>0 ){
-    sqlite_busy_handler(db, sqliteDefaultBusyCallback, (void*)ms);
+    sqlite_busy_handler(db, sqliteDefaultBusyCallback, (void*)(long)ms);
   }else{
     sqlite_busy_handler(db, 0, 0);
   }
index e1804fcb4ab504d7ad27004c807838131aed863b..165769242cf99a54a126239c20f18278dd89b6d9 100644 (file)
--- a/src/os.c
+++ b/src/os.c
@@ -464,6 +464,11 @@ int sqliteOsOpenReadWrite(
   id->dirfd = -1;
   id->fd = open(zFilename, O_RDWR|O_CREAT|O_LARGEFILE|O_BINARY, 0644);
   if( id->fd<0 ){
+#ifdef EISDIR
+    if( errno==EISDIR ){
+      return SQLITE_CANTOPEN;
+    }
+#endif
     id->fd = open(zFilename, O_RDONLY|O_LARGEFILE|O_BINARY);
     if( id->fd<0 ){
       return SQLITE_CANTOPEN; 
index 8169dbd2656e3acc3671ccdc16b17dbeaac02d73..48c852d4878f839362a7608a1428535d50cab998 100644 (file)
@@ -31,7 +31,7 @@ typedef struct TabResult {
   int nAlloc;
   int nRow;
   int nColumn;
-  int nData;
+  long nData;
   int rc;
 } TabResult;
 
@@ -196,7 +196,7 @@ void sqlite_free_table(
     int i, n;
     azResult--;
     if( azResult==0 ) return;
-    n = (int)azResult[0];
+    n = (int)(long)azResult[0];
     for(i=1; i<n; i++){ if( azResult[i] ) free(azResult[i]); }
     free(azResult);
   }
index 6254aa881d88b5af0de2ea5449dcbb1c20365b90..c206bad4ab75a062ab6daf6ea5fb1ad061ef75f4 100644 (file)
@@ -511,7 +511,7 @@ void sqliteVdbePrintOp(FILE *pOut, int pc, Op *pOp){
   char *zP3;
   char zPtr[40];
   if( pOp->p3type==P3_POINTER ){
-    sprintf(zPtr, "ptr(%#x)", (int)pOp->p3);
+    sprintf(zPtr, "ptr(%#lx)", (long)pOp->p3);
     zP3 = zPtr;
   }else{
     zP3 = pOp->p3;
@@ -565,7 +565,7 @@ int sqliteVdbeList(
     sprintf(p->zArgv[2],"%d", p->aOp[i].p1);
     sprintf(p->zArgv[3],"%d", p->aOp[i].p2);
     if( p->aOp[i].p3type==P3_POINTER ){
-      sprintf(p->aStack[4].zShort, "ptr(%#x)", (int)p->aOp[i].p3);
+      sprintf(p->aStack[4].zShort, "ptr(%#lx)", (long)p->aOp[i].p3);
       p->zArgv[4] = p->aStack[4].zShort;
     }else{
       p->zArgv[4] = p->aOp[i].p3;