/ Check-in [aa4890b9]
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:Fix the memcpy calls in the lsmWin32OsShmMap function for lsm1.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: aa4890b9f9e9698c61d6ca0e24c26280f5e0a87a8c02865933ad483a1fd44d84
User & Date: mistachkin 2017-07-07 19:12:55
Context
2017-07-07
19:22
Fix typos in Win32 VFS for lsm1. check-in: 0961ec87 user: mistachkin tags: trunk
19:12
Fix the memcpy calls in the lsmWin32OsShmMap function for lsm1. check-in: aa4890b9 user: mistachkin tags: trunk
19:02
Enhance the MSVC makefile 'clean' target to handle lsm1. check-in: 2d6faebc user: mistachkin tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to ext/lsm1/lsm_win32.c.

688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
    ahNew = (LPHANDLE)lsmMallocZero(pWin32File->pEnv, sizeof(LPHANDLE) * nNew);
    if( !ahNew ) return LSM_NOMEM_BKPT;
    apNew = (LPVOID *)lsmMallocZero(pWin32File->pEnv, sizeof(LPVOID) * nNew);
    if( !apNew ){
      lsmFree(pWin32File->pEnv, ahNew);
      return LSM_NOMEM_BKPT;
    }
    memcpy(ahNew, pWin32File->ahShm, pWin32File->nShm);
    memcpy(apNew, pWin32File->apShm, pWin32File->nShm);
    lsmFree(pWin32File->pEnv, pWin32File->ahShm);
    pWin32File->ahShm = ahNew;
    lsmFree(pWin32File->pEnv, pWin32File->apShm);
    pWin32File->apShm = apNew;
    pWin32File->nShm = nNew;
  }








|
|







688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
    ahNew = (LPHANDLE)lsmMallocZero(pWin32File->pEnv, sizeof(LPHANDLE) * nNew);
    if( !ahNew ) return LSM_NOMEM_BKPT;
    apNew = (LPVOID *)lsmMallocZero(pWin32File->pEnv, sizeof(LPVOID) * nNew);
    if( !apNew ){
      lsmFree(pWin32File->pEnv, ahNew);
      return LSM_NOMEM_BKPT;
    }
    memcpy(ahNew, pWin32File->ahShm, sizeof(LPHANDLE) * pWin32File->nShm);
    memcpy(apNew, pWin32File->apShm, sizeof(LPVOID) * pWin32File->nShm);
    lsmFree(pWin32File->pEnv, pWin32File->ahShm);
    pWin32File->ahShm = ahNew;
    lsmFree(pWin32File->pEnv, pWin32File->apShm);
    pWin32File->apShm = apNew;
    pWin32File->nShm = nNew;
  }