From 1fe922cd8b76cffdb15eac07f6e686449e1b1469 Mon Sep 17 00:00:00 2001 From: "Jay Freeman (saurik)" Date: Sun, 29 Jan 2017 05:02:26 -0800 Subject: Cytore values need to be _packed (I got lucky :D). --- Cytore.hpp | 6 +++--- MobileCydia.mm | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Cytore.hpp b/Cytore.hpp index 168f2ef..714da26 100644 --- a/Cytore.hpp +++ b/Cytore.hpp @@ -50,7 +50,7 @@ struct Header { uint32_t version_; uint32_t size_; uint32_t reserved_; -}; +} _packed; template class Offset { @@ -80,11 +80,11 @@ class Offset { bool IsNull() const { return offset_ == 0; } -}; +} _packed; struct Block { Cytore::Offset reserved_; -}; +} _packed; template static _finline Type_ Round(Type_ value, Type_ size) { diff --git a/MobileCydia.mm b/MobileCydia.mm index 32c0244..fd225d1 100644 --- a/MobileCydia.mm +++ b/MobileCydia.mm @@ -1420,14 +1420,14 @@ struct PackageValue : char version_[8]; char name_[]; -}; +} _packed; struct MetaValue : Cytore::Block { uint32_t active_; Cytore::Offset packages_[1 << 16]; -}; +} _packed; static Cytore::File MetaFile_; // }}} -- cgit v1.2.3