/ Check-in [3a2793aa]
Login
SQLite training in Houston TX on 2019-11-05 (details)
Part of the 2019 Tcl Conference

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

Overview
Comment:Remove use of the rand_s() function (added by [139081bef9f63c3e]) as it appears to cause issues with some third-party DLLs.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 3a2793aa65727cbbf8c4678d478cf8fb02350f19ff98201934a984727368d64d
User & Date: mistachkin 2017-09-12 23:58:47
Context
2017-09-13
00:01
Fix test script comment. No changes to code. check-in: a5a19492 user: mistachkin tags: trunk
2017-09-12
23:58
Remove use of the rand_s() function (added by [139081bef9f63c3e]) as it appears to cause issues with some third-party DLLs. check-in: 3a2793aa user: mistachkin tags: trunk
15:05
Fix an error in [b22cdd67] that can cause a negative infinity to be (rarely) reported as a positive infinity. check-in: 9780b23c user: drh tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to src/os_win.c.

  5692   5692     UNUSED_PARAMETER(pVfs);
  5693   5693     memset(zBuf, 0, nBuf);
  5694   5694     return nBuf;
  5695   5695   #else
  5696   5696     EntropyGatherer e;
  5697   5697     UNUSED_PARAMETER(pVfs);
  5698   5698     memset(zBuf, 0, nBuf);
  5699         -#if defined(_MSC_VER) && _MSC_VER>=1400 && !SQLITE_OS_WINCE
  5700         -  rand_s((unsigned int*)zBuf); /* rand_s() is not available with MinGW */
  5701         -#endif /* defined(_MSC_VER) && _MSC_VER>=1400 */
  5702   5699     e.a = (unsigned char*)zBuf;
  5703   5700     e.na = nBuf;
  5704   5701     e.nXor = 0;
  5705   5702     e.i = 0;
  5706   5703     {
  5707   5704       SYSTEMTIME x;
  5708   5705       osGetSystemTime(&x);

Changes to src/sqliteInt.h.

    46     46   ** Make sure the Tcl calling convention macro is defined.  This macro is
    47     47   ** only used by test code and Tcl integration code.
    48     48   */
    49     49   #ifndef SQLITE_TCLAPI
    50     50   #  define SQLITE_TCLAPI
    51     51   #endif
    52     52   
    53         -/*
    54         -** Make sure that rand_s() is available on Windows systems with MSVC 2005
    55         -** or higher.
    56         -*/
    57         -#if defined(_MSC_VER) && _MSC_VER>=1400
    58         -#  define _CRT_RAND_S
    59         -#endif
    60         -
    61     53   /*
    62     54   ** Include the header file used to customize the compiler options for MSVC.
    63     55   ** This should be done first so that it can successfully prevent spurious
    64     56   ** compiler warnings due to subsequent content in this file and other files
    65     57   ** that are included by this file.
    66     58   */
    67     59   #include "msvc.h"