summaryrefslogtreecommitdiff
path: root/postinst.mm
diff options
context:
space:
mode:
authorJay Freeman (saurik) <saurik@saurik.com>2014-10-30 03:40:02 -0700
committerJay Freeman (saurik) <saurik@saurik.com>2014-10-30 03:40:02 -0700
commit1a2f455b7019fb3b8cd06220228db88da28bf7f7 (patch)
tree8c8878c07356ab98f773639841691c2b83487642 /postinst.mm
parent4cfa3e5b08fdefca9a9f14df6b5ab8c8ea6d4e99 (diff)
Migrate metadata.cb0 to Caches from /var/lib/cydia.
Diffstat (limited to 'postinst.mm')
-rw-r--r--postinst.mm6
1 files changed, 6 insertions, 0 deletions
diff --git a/postinst.mm b/postinst.mm
index d837d7b..c6dd965 100644
--- a/postinst.mm
+++ b/postinst.mm
@@ -180,6 +180,12 @@ int main(int argc, const char *argv[]) {
system("chown -R 501.501 " NewCache_ "/lists");
}
+ if (access(NewCache_ "/metadata.cb0", F_OK) != 0 && errno == ENOENT)
+ if (access("/var/lib/cydia/metadata.cb0", F_OK) == 0) {
+ system("mv /var/lib/cydia/metadata.cb0 " NewCache_);
+ chown(NewCache_ "/metadata.cb0", 501, 501);
+ }
+
FixPermissions();
if (FixApplications())