Chameleon

Chameleon Commit Details

Date:2015-07-05 00:05:00 (4 years 4 months ago)
Author:ErmaC
Commit:2729
Parents: 2728
Message:Typo
Changes:
M/trunk/i386/boot2/drivers.c
M/trunk/i386/boot2/boot.c

File differences

trunk/i386/boot2/drivers.c
669669
670670
671671
672
672673
673674
674675
......
678679
679680
680681
682
681683
684
682685
683686
684687
......
699702
700703
701704
705
702706
703707
704708
......
710714
711715
712716
717
713718
714719
715720
716721
717722
718723
724
719725
720726
721727
722728
729
723730
724731
725732
......
10041011
10051012
10061013
1014
10071015
10081016
10091017
{
fileName = prop->string;
snprintf(gFileSpec, 4096, "%s%s", module->executablePath, fileName);
length = LoadThinFatFile(gFileSpec, &executableAddr);
if (length == 0)
{
//printf("%s length = %d addr = 0x%x\n", gFileSpec, length, driverModuleAddr); getchar();
}
else
{
length = 0;
}
if (length != -1)
{
driver = (DriverInfoPtr)driverAddr;
driver->plistAddr = (char *)(driverAddr + sizeof(DriverInfo));
driver->plistLength = module->plistLength;
if (length != 0)
{
driver->executableAddr = (void *)(driverAddr + sizeof(DriverInfo) +
driver->executableAddr = 0;
driver->executableLength = 0;
}
driver->bundlePathAddr = (void *)(driverAddr + sizeof(DriverInfo) +
module->plistLength + driver->executableLength);
driver->bundlePathLength = module->bundlePathLength;
// Save the plist, module and bundle.
strlcpy(driver->plistAddr, module->plistAddr, driver->plistLength);
if (length != 0)
{
memcpy(driver->executableAddr, executableAddr, length);
}
strlcpy(driver->bundlePathAddr, module->bundlePath, module->bundlePathLength);
// Add an entry to the memory map.
// Bungo: scan binary for Darwin Kernel Version string
uint32_t offset = 0;
strncpy(gDarwinBuildVerStr, "Darwin Kernel Version", sizeof(gDarwinBuildVerStr));
while ((offset < 0xFFFFFFFF - (uint32_t)binary - 256) && memcmp(binary + offset, gDarwinBuildVerStr, 21))
{
offset++;
trunk/i386/boot2/boot.c
316316
317317
318318
319
319
320320
321321
322322
......
325325
326326
327327
328
328
329329
330330
331331
prev_time = time;
}
}
verbose("Kernel Cache file path (Mac OS X 10.6.X): %s\n", kernelCacheFile);
verbose("Kernel Cache file path (Mac OS X 10.6.X): %s\n", kernelCachePath);
}
closedir(cacheDir);
}
// Lion, Mountain Lion, Mavericks, Yosemite and El Capitan prelink kernel cache file
// for 10.7 10.8 10.9 10.10 10.11
snprintf(kernelCacheFile, sizeof(kernelCacheFile), "%skernelcache", kDefaultCachePathSnow);
verbose("Kernel Cache file path (Mac OS X 10.7 and newer): %s\n", kernelCacheFile);
verbose("Kernel Cache file path (Mac OS X 10.7 and newer): %s\n", kernelCachePath);
}
}

Archive Download the corresponding diff file

Revision: 2729