-
Notifications
You must be signed in to change notification settings - Fork 11
Expand file tree
/
Copy pathmain.m
More file actions
34 lines (26 loc) · 751 Bytes
/
main.m
File metadata and controls
34 lines (26 loc) · 751 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
//
// main.m
// Bootlace
//
// Created by Neonkoala on 07/06/2010.
// Copyright Nick Dawson 2010. All rights reserved.
//
#import <UIKit/UIKit.h>
#import "Classes/OpeniBootClass.h"
int main(int argc, char *argv[]) {
NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init];
int retVal;
if(argc==1) {
retVal = UIApplicationMain(argc, argv, nil, nil);
} else if(strcmp(argv[1], "--kernelmd5")==0) {
printf("Checking MD5 of kernelcache...\n");
OpeniBootClass *opibInstance = [[OpeniBootClass alloc] init];
[opibInstance opibKernelMD5:[[NSString alloc] initWithUTF8String:argv[2]]];
NSLog(@"Done.");
} else {
printf("Invalid argument. Terminating.\n");
retVal = -7;
}
[pool release];
return retVal;
}