1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-08-10 01:02:56 +03:00

Fix a bug in the default busy handler for systems that lack usleep().

Ticket #1284. (CVS 2514)

FossilOrigin-Name: a42cb81d1173532537aed4e71091d4cd3f3a88a0
This commit is contained in:
drh
2005-06-14 02:24:31 +00:00
parent 78776ecdb1
commit 3f73708ce4
3 changed files with 9 additions and 9 deletions

View File

@@ -1,5 +1,5 @@
C Do\snot\srecord\sexistance\sthe\ssqlite_sequence\stable\suntil\sit\sis\sactually\ncreated.\s\sTicket\s#1283.\s(CVS\s2513) C Fix\sa\sbug\sin\sthe\sdefault\sbusy\shandler\sfor\ssystems\sthat\slack\susleep().\nTicket\s#1284.\s(CVS\s2514)
D 2005-06-14T02:12:46 D 2005-06-14T02:24:32
F Makefile.in 8129e7f261d405db783676f9ca31e0841768c652 F Makefile.in 8129e7f261d405db783676f9ca31e0841768c652
F Makefile.linux-gcc 06be33b2a9ad4f005a5f42b22c4a19dab3cbb5c7 F Makefile.linux-gcc 06be33b2a9ad4f005a5f42b22c4a19dab3cbb5c7
F README 9c4e2d6706bdcc3efdd773ce752a8cdab4f90028 F README 9c4e2d6706bdcc3efdd773ce752a8cdab4f90028
@@ -43,7 +43,7 @@ F src/hash.c 2b1b13f7400e179631c83a1be0c664608c8f021f
F src/hash.h 1b0c445e1c89ff2aaad9b4605ba61375af001e84 F src/hash.h 1b0c445e1c89ff2aaad9b4605ba61375af001e84
F src/insert.c 8c0868a975fe37366ed92e1b976853be96284607 F src/insert.c 8c0868a975fe37366ed92e1b976853be96284607
F src/legacy.c d58ea507bce885298a2c8c3cbb0f4bff5d47830b F src/legacy.c d58ea507bce885298a2c8c3cbb0f4bff5d47830b
F src/main.c f61bdb0a1afeb2eff7285f4f3752e1085ecc55ed F src/main.c 7d0293d9520688d47092ff48c1ed5254cd3c4474
F src/md5.c 7ae1c39044b95de2f62e066f47bb1deb880a1070 F src/md5.c 7ae1c39044b95de2f62e066f47bb1deb880a1070
F src/os.h c4b34bd4d6fea51a420f337468b907f4edecb161 F src/os.h c4b34bd4d6fea51a420f337468b907f4edecb161
F src/os_common.h 0e7f428ba0a6c40a61bc56c4e96f493231301b73 F src/os_common.h 0e7f428ba0a6c40a61bc56c4e96f493231301b73
@@ -281,7 +281,7 @@ F www/tclsqlite.tcl 425be741b8ae664f55cb1ef2371aab0a75109cf9
F www/vdbe.tcl 87a31ace769f20d3627a64fa1fade7fed47b90d0 F www/vdbe.tcl 87a31ace769f20d3627a64fa1fade7fed47b90d0
F www/version3.tcl a99cf5f6d8bd4d5537584a2b342f0fb9fa601d8b F www/version3.tcl a99cf5f6d8bd4d5537584a2b342f0fb9fa601d8b
F www/whentouse.tcl 528299b8316726dbcc5548e9aa0648c8b1bd055b F www/whentouse.tcl 528299b8316726dbcc5548e9aa0648c8b1bd055b
P ce6b62fa46bc67085801c48d6a28944d4d373ba9 P 95256d953c179372dcc5ead6c407672c8161a8c1
R 9d8a9caa3f6f6c80defde0cdf07c4d4f R 815fb7da58112e0d675890ca68b74255
U drh U drh
Z 314129c4c40699681e64c32b930006f5 Z 492e3cae79332462e050d4e103baeade

View File

@@ -1 +1 @@
95256d953c179372dcc5ead6c407672c8161a8c1 a42cb81d1173532537aed4e71091d4cd3f3a88a0

View File

@@ -14,7 +14,7 @@
** other files are for internal use by SQLite and should not be ** other files are for internal use by SQLite and should not be
** accessed by users of the library. ** accessed by users of the library.
** **
** $Id: main.c,v 1.293 2005/05/26 16:23:34 drh Exp $ ** $Id: main.c,v 1.294 2005/06/14 02:24:32 drh Exp $
*/ */
#include "sqliteInt.h" #include "sqliteInt.h"
#include "os.h" #include "os.h"
@@ -298,7 +298,7 @@ static int sqliteDefaultBusyCallback(
sqlite3OsSleep(delay); sqlite3OsSleep(delay);
return 1; return 1;
#else #else
int timeout = (int)Timeout; int timeout = ((sqlite3 *)ptr)->busyTimeout;
if( (count+1)*1000 > timeout ){ if( (count+1)*1000 > timeout ){
return 0; return 0;
} }