Skip to content

Commit 92c4478

Browse files
committed
fix patch size issue & bump version
1 parent f8174a1 commit 92c4478

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

Resources/Info.plist

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -293,9 +293,9 @@
293293
<key>UILaunchStoryboardName</key>
294294
<string>LaunchScreen</string>
295295
<key>CFBundleVersion</key>
296-
<string>1.3.1</string>
296+
<string>1.3.2</string>
297297
<key>CFBundleShortVersionString</key>
298-
<string>1.3.1</string>
298+
<string>1.3.2</string>
299299
<key>LSRequiresIPhoneOS</key>
300300
<true/>
301301
<key>UIDeviceFamily</key>

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
1.3.1
1+
1.3.2

control

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Package: com.geode.launcher
22
Name: Geode
3-
Version: 1.3.1
3+
Version: 1.3.2
44
Architecture: iphoneos-arm
55
Description: Geode launcher helper for iOS!
66
Maintainer: Firee

src/Patcher.mm

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -829,14 +829,14 @@ + (void)patchGDBinary:(NSURL*)from to:(NSURL*)to withHandlerAddress:(uint64_t)ha
829829
NSArray<NSTextCheckingResult*>* staticMatches = [Patcher getStaticPatchesOffsetsFromData:dataString];
830830
for (NSTextCheckingResult* match in staticMatches) {
831831
NSString *sizeString = [dataString substringWithRange:[match rangeAtIndex:1]];
832-
NSUInteger patchSize = [sizeString integerValue];
832+
NSUInteger patchSize = strtoul([sizeString UTF8String], NULL, 16);
833833
NSData *patchData = [[dataString substringWithRange:[match rangeAtIndex:2]] dataUsingEncoding:NSISOLatin1StringEncoding];
834834

835835
NSString *strAddr = [NSString stringWithFormat:@"0x%@", [dataString substringWithRange:[match rangeAtIndex:3]]];
836836
NSUInteger addr = strtoull([strAddr UTF8String], NULL, 0);
837837

838838
[data replaceBytesInRange:NSMakeRange(addr, patchSize) withBytes:patchData.bytes];
839-
AppLogDebug(@"Patched Offset %#llx with %i bytes (%@)", addr, patchSize, [Patcher hexStringWithSpaces:patchData includeSpaces:YES]);
839+
AppLog(@"Patched Offset %#llx with %i bytes (%@)", addr, patchSize, [Patcher hexStringWithSpaces:patchData includeSpaces:YES]);
840840
}
841841
if (entitlements && ![[[modDictSort objectAtIndex:i] lastPathComponent] isEqualToString:@"Geode.ios.dylib"]) {
842842
[fm copyItemAtPath:[modDictSort objectAtIndex:i] toPath:[[bundlePath URLByAppendingPathComponent:@"mods"] URLByAppendingPathComponent:[[modDictSort objectAtIndex:i] lastPathComponent]].path error:nil];

0 commit comments

Comments
 (0)