sqlite: Backport Windows VFS fix.

Original change:
https://www.sqlite.org/src/info/8576ccb479fc4b76

Original change description:
Make the winTruncate() method of the windows VFS be a no-op if there are
outstanding references to the memory-mapped pages. Otherwise, memory
might be deleted out from under those references when the file is
remapped during the truncate operation.

TBR=cmumford

Bug: 897576
Change-Id: I699a92f342b1fda39979f8a8922bce03160ac3da
Reviewed-on: https://chromium-review.googlesource.com/c/1349462
Reviewed-by: Victor Costan <pwnall@chromium.org>
Commit-Queue: Victor Costan <pwnall@chromium.org>
Cr-Commit-Position: refs/heads/master@{#610715}
3 files changed