summaryrefslogtreecommitdiff
path: root/MobileCydia.mm
diff options
context:
space:
mode:
authorJay Freeman (saurik) <saurik@saurik.com>2012-03-06 22:57:26 -0800
committerJay Freeman (saurik) <saurik@saurik.com>2012-03-06 23:34:08 -0800
commitd1c7f1fd95448c4e6aee4ff164f7ff47f5d41255 (patch)
tree3030695dc9c1bb4d9bf77d492a363357e1ec0b37 /MobileCydia.mm
parent57f0b05d173f38e3f57494b84c895cfeaf9f3091 (diff)
Use our Cydia cache folder for WebKit LocalStorage.
Diffstat (limited to 'MobileCydia.mm')
-rw-r--r--MobileCydia.mm6
1 files changed, 5 insertions, 1 deletions
diff --git a/MobileCydia.mm b/MobileCydia.mm
index 2c94da8..6f26c87 100644
--- a/MobileCydia.mm
+++ b/MobileCydia.mm
@@ -260,6 +260,8 @@ NSString *Elision_;
static NSString *Error_;
static NSString *Warning_;
+static NSString *Cache_;
+
static bool AprilFools_;
static void (*$SBSSetInterceptsMenuButtonForever)(bool);
@@ -10183,7 +10185,7 @@ _trace();
[NSURLCache setSharedURLCache:[[[CYURLCache alloc]
initWithMemoryCapacity:524288
diskCapacity:10485760
- diskPath:[NSString stringWithFormat:@"%@/Library/Caches/com.saurik.Cydia/SDURLCache", @"/var/root"]
+ diskPath:[NSString stringWithFormat:@"%@/SDURLCache", Cache_]
] autorelease]];
[CydiaWebViewController _initialize];
@@ -10636,6 +10638,8 @@ int main(int argc, char *argv[]) {
if (access("/var/mobile/Library/Keyboard/UserDictionary.sqlite", F_OK) == 0)
system("mkdir -p /var/root/Library/Keyboard; cp -af /var/mobile/Library/Keyboard/UserDictionary.sqlite /var/root/Library/Keyboard/");
+ Cache_ = [[NSString stringWithFormat:@"%@/Library/Caches/com.saurik.Cydia", @"/var/root"] retain];
+
/*Method alloc = class_getClassMethod([NSObject class], @selector(alloc));
alloc_ = alloc->method_imp;
alloc->method_imp = (IMP) &Alloc_;*/