]> git.ipfire.org Git - thirdparty/sqlite.git/commitdiff
Attempt to get the filectrl.test script running.
authordrh <drh@noemail.net>
Tue, 1 Jun 2010 00:28:42 +0000 (00:28 +0000)
committerdrh <drh@noemail.net>
Tue, 1 Jun 2010 00:28:42 +0000 (00:28 +0000)
FossilOrigin-Name: e46a8f2b752f86c4d8942ee125210516026ffdc2

manifest
manifest.uuid
src/test1.c
test/filectrl.test

index ed549d9da61a1fb463a66bec4e8e306c27748075..16b6c1f1772651a1f9f9750b9059a9f83bc8c725 100644 (file)
--- a/manifest
+++ b/manifest
@@ -1,5 +1,5 @@
-C Fix\sos_unix.c\sso\sthat\sit\swill\scompile\sand\sbuild\son\sa\sMac.
-D 2010-06-01T00:03:57
+C Attempt\sto\sget\sthe\sfilectrl.test\sscript\srunning.
+D 2010-06-01T00:28:43
 F Makefile.arm-wince-mingw32ce-gcc fcd5e9cd67fe88836360bb4f9ef4cb7f8e2fb5a0
 F Makefile.in a5cad1f8f3e021356bfcc6c77dc16f6f1952bbc3
 F Makefile.linux-gcc d53183f4aa6a9192d249731c90dbdffbd2c68654
@@ -175,7 +175,7 @@ F src/sqliteLimit.h 196e2f83c3b444c4548fc1874f52f84fdbda40f3
 F src/status.c 4df6fe7dce2d256130b905847c6c60055882bdbe
 F src/table.c 2cd62736f845d82200acfa1287e33feb3c15d62e
 F src/tclsqlite.c 6bc5fbde634b9cb42b3d29d674fa6cd0c22c0881
-F src/test1.c c6f5faf649bea873685c27f6030c5ab6b2ec782a
+F src/test1.c e3e0ad1f0763a1aa6adf7e1c50727718eaa4bd32
 F src/test2.c 31f1b9d076b4774a22d2605d0af1f34e14a9a7bd
 F src/test3.c 4c21700c73a890a47fc685c1097bfb661346ac94
 F src/test4.c ad03bb987ddedce928f4258c1e7fa4109a73497d
@@ -347,7 +347,7 @@ F test/exclusive.test 4d8a112d6c5bf52014e9383c25ff193cc4f67185
 F test/exclusive2.test 6bdf254770a843c2933b54bee9ed239934f0a183
 F test/exec.test e949714dc127eaa5ecc7d723efec1ec27118fdd7
 F test/expr.test 9f521ae22f00e074959f72ce2e55d46b9ed23f68
-F test/filectrl.test 8923a6dc7630f31c8a9dd3d3d740aa0922df7bf8
+F test/filectrl.test 97003734290887566e01dded09dc9e99cb937e9e
 F test/filefmt.test 84e3d0fe9f12d0d2ac852465c6f8450aea0d6f43
 F test/fkey1.test 01c7de578e11747e720c2d9aeef27f239853c4da
 F test/fkey2.test 098c06c139a79f690301a43511cd1f6420ae5433
@@ -815,7 +815,7 @@ F tool/speedtest2.tcl ee2149167303ba8e95af97873c575c3e0fab58ff
 F tool/speedtest8.c 2902c46588c40b55661e471d7a86e4dd71a18224
 F tool/speedtest8inst1.c 293327bc76823f473684d589a8160bde1f52c14e
 F tool/vdbe-compress.tcl d70ea6d8a19e3571d7ab8c9b75cba86d1173ff0f
-P 8deba0cebd135a18da68530fab9e7d19dc21ddcb
-R 9f04a6c8c3855aa2715f2066a0bb6a2a
+P bc707c83e5f9849d9d201d695d0d071ca9ed93cb
+R ae102866b2fd164e7001ff9fe230b9d8
 U drh
-Z 4cbd37d85a5a7f671b8f563aa4494f83
+Z ebdd27e86d236f32028490bc4dcd2173
index 24eaa2be823cf0c4ee79f4f91e62e12bdd879988..127181b1639a21f990d36cfa209f914d40b157c6 100644 (file)
@@ -1 +1 @@
-bc707c83e5f9849d9d201d695d0d071ca9ed93cb
\ No newline at end of file
+e46a8f2b752f86c4d8942ee125210516026ffdc2
\ No newline at end of file
index 769c97b910f71f4ab790c86a7b214475dc1fbf17..e636bb1b8938d4591f8d6cdcce396ec33982e26e 100644 (file)
@@ -4609,7 +4609,7 @@ static int file_control_lasterrno_test(
 }
 
 /*
-** tclcmd:   file_control_lockproxy_test DB
+** tclcmd:   file_control_lockproxy_test DB PWD
 **
 ** This TCL command runs the sqlite3_file_control interface and
 ** verifies correct operation of the SQLITE_GET_LOCKPROXYFILE and
@@ -4622,15 +4622,18 @@ static int file_control_lockproxy_test(
   Tcl_Obj *CONST objv[]  /* Command arguments */
 ){
   sqlite3 *db;
+  const char *zPwd;
+  int nPwd;
   
-  if( objc!=2 ){
+  if( objc!=3 ){
     Tcl_AppendResult(interp, "wrong # args: should be \"",
-                     Tcl_GetStringFromObj(objv[0], 0), " DB", 0);
+                     Tcl_GetStringFromObj(objv[0], 0), " DB PWD", 0);
     return TCL_ERROR;
   }
   if( getDbPointer(interp, Tcl_GetString(objv[1]), &db) ){
    return TCL_ERROR;
   }
+  zPwd = Tcl_GetStringFromObj(objv[2], &nPwd);
   
 #if !defined(SQLITE_ENABLE_LOCKING_STYLE)
 #  if defined(__APPLE__)
@@ -4641,9 +4644,15 @@ static int file_control_lockproxy_test(
 #endif
 #if SQLITE_ENABLE_LOCKING_STYLE && defined(__APPLE__)
   {
-    char *proxyPath = "test.proxy";
     char *testPath;
     int rc;
+    char proxyPath[400];
+    
+    if( sizeof(proxyPath)<nPwd+20 ){
+      Tcl_AppendResult(interp, "PWD too big", (void*)0);
+      return TCL_ERROR;
+    }
+    sprintf(proxyPath, "%s/test.proxy", zPwd);
     rc = sqlite3_file_control(db, NULL, SQLITE_SET_LOCKPROXYFILE, proxyPath);
     if( rc ){
       Tcl_SetObjResult(interp, Tcl_NewIntObj(rc)); 
index fe89a62635aa62115a14a558e92b290b65dc859a..67e81830c4a31287c51d06f3a28142c36fb88375 100644 (file)
@@ -34,7 +34,7 @@ do_test filectrl-1.4 {
 do_test filectrl-1.5 {
   db close
   sqlite3 db test_control_lockproxy.db
-  file_control_lockproxy_test db
+  file_control_lockproxy_test db [pwd]
 } {}
 db close
 file delete -force .test_control_lockproxy.db-conch test.proxy