[release/8.0.1xx] Source-build dotnet/runtime patch: crashinfo.cpp/crasinfounix.cpp: use off_t instead of off64_t (#19544)
Co-authored-by: Michael Simons <msimons@microsoft.com>
This commit is contained in:
parent
46532a34a8
commit
05ce03283e
1 changed files with 38 additions and 0 deletions
|
@ -0,0 +1,38 @@
|
|||
From 05ad51a9be428012328a1ee199a4edaff20b5efe Mon Sep 17 00:00:00 2001
|
||||
From: Antoine Martin <dev@ayakael.net>
|
||||
Date: Tue, 12 Sep 2023 18:55:46 -0400
|
||||
Subject: [PATCH] crashinfo.cpp/crasinfounix.cpp: use off_t instead of off64_t
|
||||
|
||||
Backport: https://github.com/dotnet/runtime/pull/101272
|
||||
|
||||
---
|
||||
src/coreclr/debug/createdump/crashinfo.cpp | 2 +-
|
||||
src/coreclr/debug/createdump/crashinfounix.cpp | 2 +-
|
||||
2 files changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/src/coreclr/debug/createdump/crashinfo.cpp b/src/coreclr/debug/createdump/crashinfo.cpp
|
||||
index 996f3a81935d..d1d1b0ea0218 100644
|
||||
--- a/src/coreclr/debug/createdump/crashinfo.cpp
|
||||
+++ b/src/coreclr/debug/createdump/crashinfo.cpp
|
||||
@@ -803,7 +803,7 @@ CrashInfo::PageMappedToPhysicalMemory(uint64_t start)
|
||||
}
|
||||
|
||||
uint64_t pagemapOffset = (start / PAGE_SIZE) * sizeof(uint64_t);
|
||||
- uint64_t seekResult = lseek64(m_fdPagemap, (off64_t) pagemapOffset, SEEK_SET);
|
||||
+ uint64_t seekResult = lseek(m_fdPagemap, (off_t) pagemapOffset, SEEK_SET);
|
||||
if (seekResult != pagemapOffset)
|
||||
{
|
||||
int seekErrno = errno;
|
||||
diff --git a/src/coreclr/debug/createdump/crashinfounix.cpp b/src/coreclr/debug/createdump/crashinfounix.cpp
|
||||
index 24b975e3d655..2f4ea079de3b 100644
|
||||
--- a/src/coreclr/debug/createdump/crashinfounix.cpp
|
||||
+++ b/src/coreclr/debug/createdump/crashinfounix.cpp
|
||||
@@ -516,7 +516,7 @@ CrashInfo::ReadProcessMemory(void* address, void* buffer, size_t size, size_t* r
|
||||
// performance optimization.
|
||||
m_canUseProcVmReadSyscall = false;
|
||||
assert(m_fdMem != -1);
|
||||
- *read = pread64(m_fdMem, buffer, size, (off64_t)address);
|
||||
+ *read = pread(m_fdMem, buffer, size, (off_t)address);
|
||||
}
|
||||
|
||||
if (*read == (size_t)-1)
|
Loading…
Reference in a new issue