/ Check-in [67b3c0ef]
Login

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

Overview
Comment:Fix the xCheckReservedLock() method on the windows VFS so that it cannot return a false positive when two or more processes use it at the same time on the same file. Ticket [7ff3120e4fa54abb55]. Update to version 3.7.16.2.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | sessions
Files: files | file ages | folders
SHA1: 67b3c0efa7d5e0cb7cc0fc7606ab3f26ea5419fd
User & Date: drh 2013-04-12 13:53:50
Context
2013-04-22
23:59
Merge the latest trunk changes into the sessions branch. check-in: 6994826c user: drh tags: sessions
2013-04-12
13:53
Fix the xCheckReservedLock() method on the windows VFS so that it cannot return a false positive when two or more processes use it at the same time on the same file. Ticket [7ff3120e4fa54abb55]. Update to version 3.7.16.2. check-in: 67b3c0ef user: drh tags: sessions
11:52
Version 3.7.16.2 Leaf check-in: cbea02d9 user: drh tags: release, version-3.7.16.2, branch-3.7.16
2013-04-11
00:45
Correct minor typo in two regular expressions. check-in: f1eed92b user: mistachkin tags: sessions
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to VERSION.

     1         -3.7.16.1
            1  +3.7.16.2

Changes to configure.

     1      1   #! /bin/sh
     2      2   # Guess values for system-dependent variables and create Makefiles.
     3         -# Generated by GNU Autoconf 2.62 for sqlite 3.7.16.1.
            3  +# Generated by GNU Autoconf 2.62 for sqlite 3.7.16.2.
     4      4   #
     5      5   # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
     6      6   # 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
     7      7   # This configure script is free software; the Free Software Foundation
     8      8   # gives unlimited permission to copy, distribute and modify it.
     9      9   ## --------------------- ##
    10     10   ## M4sh Initialization.  ##
................................................................................
   739    739   MFLAGS=
   740    740   MAKEFLAGS=
   741    741   SHELL=${CONFIG_SHELL-/bin/sh}
   742    742   
   743    743   # Identity of this package.
   744    744   PACKAGE_NAME='sqlite'
   745    745   PACKAGE_TARNAME='sqlite'
   746         -PACKAGE_VERSION='3.7.16.1'
   747         -PACKAGE_STRING='sqlite 3.7.16.1'
          746  +PACKAGE_VERSION='3.7.16.2'
          747  +PACKAGE_STRING='sqlite 3.7.16.2'
   748    748   PACKAGE_BUGREPORT=''
   749    749   
   750    750   # Factoring default headers for most tests.
   751    751   ac_includes_default="\
   752    752   #include <stdio.h>
   753    753   #ifdef HAVE_SYS_TYPES_H
   754    754   # include <sys/types.h>
................................................................................
  1480   1480   #
  1481   1481   # Report the --help message.
  1482   1482   #
  1483   1483   if test "$ac_init_help" = "long"; then
  1484   1484     # Omit some internal or obsolete options to make the list less imposing.
  1485   1485     # This message is too long to be a string in the A/UX 3.1 sh.
  1486   1486     cat <<_ACEOF
  1487         -\`configure' configures sqlite 3.7.16.1 to adapt to many kinds of systems.
         1487  +\`configure' configures sqlite 3.7.16.2 to adapt to many kinds of systems.
  1488   1488   
  1489   1489   Usage: $0 [OPTION]... [VAR=VALUE]...
  1490   1490   
  1491   1491   To assign environment variables (e.g., CC, CFLAGS...), specify them as
  1492   1492   VAR=VALUE.  See below for descriptions of some of the useful variables.
  1493   1493   
  1494   1494   Defaults for the options are specified in brackets.
................................................................................
  1545   1545     --build=BUILD     configure for building on BUILD [guessed]
  1546   1546     --host=HOST       cross-compile to build programs to run on HOST [BUILD]
  1547   1547   _ACEOF
  1548   1548   fi
  1549   1549   
  1550   1550   if test -n "$ac_init_help"; then
  1551   1551     case $ac_init_help in
  1552         -     short | recursive ) echo "Configuration of sqlite 3.7.16.1:";;
         1552  +     short | recursive ) echo "Configuration of sqlite 3.7.16.2:";;
  1553   1553      esac
  1554   1554     cat <<\_ACEOF
  1555   1555   
  1556   1556   Optional Features:
  1557   1557     --disable-option-checking  ignore unrecognized --enable/--with options
  1558   1558     --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
  1559   1559     --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
................................................................................
  1661   1661       cd "$ac_pwd" || { ac_status=$?; break; }
  1662   1662     done
  1663   1663   fi
  1664   1664   
  1665   1665   test -n "$ac_init_help" && exit $ac_status
  1666   1666   if $ac_init_version; then
  1667   1667     cat <<\_ACEOF
  1668         -sqlite configure 3.7.16.1
         1668  +sqlite configure 3.7.16.2
  1669   1669   generated by GNU Autoconf 2.62
  1670   1670   
  1671   1671   Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
  1672   1672   2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
  1673   1673   This configure script is free software; the Free Software Foundation
  1674   1674   gives unlimited permission to copy, distribute and modify it.
  1675   1675   _ACEOF
  1676   1676     exit
  1677   1677   fi
  1678   1678   cat >config.log <<_ACEOF
  1679   1679   This file contains any messages produced by compilers while
  1680   1680   running configure, to aid debugging if configure makes a mistake.
  1681   1681   
  1682         -It was created by sqlite $as_me 3.7.16.1, which was
         1682  +It was created by sqlite $as_me 3.7.16.2, which was
  1683   1683   generated by GNU Autoconf 2.62.  Invocation command line was
  1684   1684   
  1685   1685     $ $0 $@
  1686   1686   
  1687   1687   _ACEOF
  1688   1688   exec 5>>config.log
  1689   1689   {
................................................................................
 14028  14028   
 14029  14029   exec 6>&1
 14030  14030   
 14031  14031   # Save the log message, to keep $[0] and so on meaningful, and to
 14032  14032   # report actual input values of CONFIG_FILES etc. instead of their
 14033  14033   # values after options handling.
 14034  14034   ac_log="
 14035         -This file was extended by sqlite $as_me 3.7.16.1, which was
        14035  +This file was extended by sqlite $as_me 3.7.16.2, which was
 14036  14036   generated by GNU Autoconf 2.62.  Invocation command line was
 14037  14037   
 14038  14038     CONFIG_FILES    = $CONFIG_FILES
 14039  14039     CONFIG_HEADERS  = $CONFIG_HEADERS
 14040  14040     CONFIG_LINKS    = $CONFIG_LINKS
 14041  14041     CONFIG_COMMANDS = $CONFIG_COMMANDS
 14042  14042     $ $0 $@
................................................................................
 14081  14081   $config_commands
 14082  14082   
 14083  14083   Report bugs to <bug-autoconf@gnu.org>."
 14084  14084   
 14085  14085   _ACEOF
 14086  14086   cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
 14087  14087   ac_cs_version="\\
 14088         -sqlite config.status 3.7.16.1
        14088  +sqlite config.status 3.7.16.2
 14089  14089   configured by $0, generated by GNU Autoconf 2.62,
 14090  14090     with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
 14091  14091   
 14092  14092   Copyright (C) 2008 Free Software Foundation, Inc.
 14093  14093   This config.status script is free software; the Free Software Foundation
 14094  14094   gives unlimited permission to copy, distribute and modify it."
 14095  14095   

Changes to src/os_win.c.

  2637   2637     SimulateIOError( return SQLITE_IOERR_CHECKRESERVEDLOCK; );
  2638   2638   
  2639   2639     assert( id!=0 );
  2640   2640     if( pFile->locktype>=RESERVED_LOCK ){
  2641   2641       rc = 1;
  2642   2642       OSTRACE(("TEST WR-LOCK %d %d (local)\n", pFile->h, rc));
  2643   2643     }else{
  2644         -    rc = winLockFile(&pFile->h, SQLITE_LOCKFILE_FLAGS, RESERVED_BYTE, 0, 1, 0);
         2644  +    rc = winLockFile(&pFile->h, SQLITE_LOCKFILEEX_FLAGS,RESERVED_BYTE, 0, 1, 0);
  2645   2645       if( rc ){
  2646   2646         winUnlockFile(&pFile->h, RESERVED_BYTE, 0, 1, 0);
  2647   2647       }
  2648   2648       rc = !rc;
  2649   2649       OSTRACE(("TEST WR-LOCK %d %d (remote)\n", pFile->h, rc));
  2650   2650     }
  2651   2651     *pResOut = rc;

Changes to src/util.c.

   516    516       *pNum = -(i64)u;
   517    517     }else{
   518    518       *pNum = (i64)u;
   519    519     }
   520    520     testcase( i==18 );
   521    521     testcase( i==19 );
   522    522     testcase( i==20 );
   523         -  if( (c+nonNum!=0 && &zNum[i]<zEnd) || (i==0 && zStart==zNum) || i>19*incr ){
          523  +  if( (c!=0 && &zNum[i]<zEnd) || (i==0 && zStart==zNum) || i>19*incr || nonNum ){
   524    524       /* zNum is empty or contains non-numeric text or is longer
   525    525       ** than 19 digits (thus guaranteeing that it is too large) */
   526    526       return 1;
   527    527     }else if( i<19*incr ){
   528    528       /* Less than 19 digits, so we know that it fits in 64 bits */
   529    529       assert( u<=LARGEST_INT64 );
   530    530       return 0;