[llvm-commits] CVS: llvm/lib/System/Win32/Path.inc
Reid Spencer
reid at x10sys.com
Thu Jun 8 10:00:21 PDT 2006
Changes in directory llvm/lib/System/Win32:
Path.inc updated: 1.43 -> 1.44
---
Log message:
For PR804: http://llvm.org/PR804 :
Change the file size field of StatusInfo to be uint64_t instead of size_t
so that we know it is always 64 bits. This prevents some overflow on
systems where size_t is 32 bits when it ought to be 64.
---
Diffs of the changes: (+1 -1)
Path.inc | 2 +-
1 files changed, 1 insertion(+), 1 deletion(-)
Index: llvm/lib/System/Win32/Path.inc
diff -u llvm/lib/System/Win32/Path.inc:1.43 llvm/lib/System/Win32/Path.inc:1.44
--- llvm/lib/System/Win32/Path.inc:1.43 Mon Jun 5 10:44:46 2006
+++ llvm/lib/System/Win32/Path.inc Thu Jun 8 12:00:08 2006
@@ -340,7 +340,7 @@
ThrowError("getStatusInfo():" + std::string(path) + ": Can't get status: ");
info.fileSize = fi.nFileSizeHigh;
- info.fileSize <<= 32;
+ info.fileSize <<= sizeof(fi.nFileSizeHigh)*8;
info.fileSize += fi.nFileSizeLow;
info.mode = fi.dwFileAttributes & FILE_ATTRIBUTE_READONLY ? 0555 : 0777;
More information about the llvm-commits
mailing list