[PATCH] D39876: [support] allocate exact size required for mapping in Support/Windws/Path.inc

Bob Haarman via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Nov 9 16:17:43 PST 2017


This revision was automatically updated to reflect the committed changes.
Closed by commit rL317850: [support] allocate exact size required for mapping in Support/Windws/Path.inc (authored by inglorion).

Changed prior to commit:
  https://reviews.llvm.org/D39876?vs=122350&id=122357#toc

Repository:
  rL LLVM

https://reviews.llvm.org/D39876

Files:
  llvm/trunk/lib/Support/Windows/Path.inc


Index: llvm/trunk/lib/Support/Windows/Path.inc
===================================================================
--- llvm/trunk/lib/Support/Windows/Path.inc
+++ llvm/trunk/lib/Support/Windows/Path.inc
@@ -734,8 +734,8 @@
 
   HANDLE FileMappingHandle =
       ::CreateFileMappingW(FileHandle, 0, flprotect,
-                           (Offset + Size) >> 32,
-                           (Offset + Size) & 0xffffffff,
+                           Size >> 32,
+                           Size & 0xffffffff,
                            0);
   if (FileMappingHandle == NULL) {
     std::error_code ec = mapWindowsError(GetLastError());


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D39876.122357.patch
Type: text/x-patch
Size: 632 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20171110/dd772693/attachment.bin>


More information about the llvm-commits mailing list