Loading...
--- dyld/dyld-1122.1/common/ProcessAtlas.cpp
+++ dyld/dyld-1066.8/common/ProcessAtlas.cpp
@@ -24,8 +24,6 @@
#include <TargetConditionals.h>
-#if !TARGET_OS_EXCLAVEKIT
-
#include <atomic>
#include <cstring>
#include <Block.h>
@@ -41,8 +39,8 @@
#include <sys/stat.h>
#include <sys/fsgetpath.h>
+#include <mach/mach_vm.h>
#include <mach/mach_time.h> // mach_absolute_time()
-#include <mach/mach_vm.h>
#include <mach-o/dyld_priv.h> // FIXME: We can remove this once we fully integrate into dyld4
#include "dyld_cache_format.h"
//FIXME: We should remove this header
@@ -590,9 +588,9 @@
#if BUILDING_DYLD
Image::Image(RuntimeState* state, Allocator& ephemeralAllocator, SharedPtr<Mapper>& mapper, const Loader* ldr)
: _ephemeralAllocator(ephemeralAllocator), _mapper(mapper), _rebasedAddress((void*)ldr->loadAddress(*state)) {
- auto fileID = ldr->fileID(*state);
+ auto fileID = ldr->fileID(state->fileManager);
if (fileID.inode() && fileID.device()) {
- _file = state->fileManager.fileRecordForFileID(ldr->fileID(*state));
+ _file = state->fileManager.fileRecordForFileID(ldr->fileID(state->fileManager));
if ( _file.volume().empty() ) {
_file = state->fileManager.fileRecordForPath(ephemeralAllocator, ldr->path());
}
@@ -2007,17 +2005,17 @@
_timestamp = read<uint64_t>(i);
_crc32c = read<uint32_t>(i);
if (_magic != kMagic) {
- return false;
+ assert(0);
}
if (_version != 0) {
- return false;
+ assert(0);
}
CRC32c checksumer;
checksumer(std::span(&data[0], 32));
checksumer((uint32_t)0); // Zero out the actual checksum
checksumer(std::span(&data[36], data.size() - 36));
if (_crc32c != checksumer) {
- return false;
+ assert(0);
}
_processFlags = readPVLEUInt64(i);
_platform = readPVLEUInt64(i);
@@ -2084,4 +2082,3 @@
};
};
-#endif // !TARGET_OS_EXCLAVEKIT