/ Check-in [63599fa5]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Fix the usleep() macro in the Win32 test code for lsm1.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 63599fa524a7c72ffa5362041f2ec394d9af9c43025d8b6d5a34e98eb423d5ff
User & Date: mistachkin 2017-07-07 17:57:21
Context
2017-07-07
18:06
In the command-line shell, when running ".schema" give a sensible error when the database file is locked. check-in: cc329eb8 user: drh tags: trunk
17:57
Fix the usleep() macro in the Win32 test code for lsm1. check-in: 63599fa5 user: mistachkin tags: trunk
17:43
Add new PRAGMAs: "function_list", "module_list", and "pragma_list". All are enclosed within #ifdef SQLITE_INTROSPECTION_PRAGMAS. The compile-time option is not on ctime.c yet, since these are still experimental and one can always test "PRAGMA pragma_list" and see whether or not it returns an empty set. check-in: e0b6ae92 user: drh tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to ext/lsm1/lsm-test/lsmtest.h.

    16     16   #endif
    17     17   
    18     18   #ifdef _WIN32
    19     19   # include "windows.h"
    20     20   # define gettimeofday win32GetTimeOfDay
    21     21   # define F_OK  (0)
    22     22   # define sleep(sec) Sleep(1000 * (sec))
    23         -# define usleep(usec) Sleep((usec) / 1000)
           23  +# define usleep(usec) Sleep(((usec) + 999) / 1000)
    24     24   # ifdef _MSC_VER
    25     25   #  include <io.h>
    26     26   #  define snprintf _snprintf
    27     27   #  define fsync(fd) FlushFileBuffers((HANDLE)_get_osfhandle((fd)))
    28     28   #  define fdatasync(fd) FlushFileBuffers((HANDLE)_get_osfhandle((fd)))
    29     29   #  define __va_copy(dst,src) ((dst) = (src))
    30     30   #  define ftruncate(fd,sz) ((_chsize_s((fd), (sz))==0) ? 0 : -1)