diff options
author | Sam Bingner <sam@bingner.com> | 2024-01-11 14:02:40 -1000 |
---|---|---|
committer | Sam Bingner <sam@bingner.com> | 2024-01-11 14:02:40 -1000 |
commit | 0c426991076e724613c36431c59d8ef66838598b (patch) | |
tree | d2d5fcd1c2d0ebd19563676552ee12d577ddb52f | |
parent | 448a3d8e7f47b581f68bdd994d1286ca9b921e6b (diff) |
-rw-r--r-- | sbreload.m | 14 |
1 files changed, 14 insertions, 0 deletions
@@ -64,7 +64,13 @@ #define FLAG_PLATFORMIZE (1 << 1) #include <dlfcn.h> #include <objc/runtime.h> + +#ifndef __IPHONE_10_0 +#define __IPHONE_10_0 100000 +#endif +#if __IPHONE_OS_VERSION_MIN_REQUIRED >= __IPHONE_10_0 #include <xpc/xpc.h> +#endif @interface FBSSystemService +(id)sharedService; @@ -165,9 +171,13 @@ CF2launch_data(CFTypeRef cfr) case kCFNumberLongType: case kCFNumberLongLongType: CFNumberGetValue(cfr, kCFNumberLongLongType, &n); +#if __IPHONE_OS_VERSION_MIN_REQUIRED >= __IPHONE_10_0 if (kCFCoreFoundationVersionNumber >= 1443.00) { r = (launch_data_t)xpc_int64_create(n); } else { +#else + { +#endif // This hangs forever if I call it on new iOS??? r = launch_data_alloc(LAUNCH_DATA_INTEGER); launch_data_set_integer(r, n); @@ -178,9 +188,13 @@ CF2launch_data(CFTypeRef cfr) case kCFNumberFloatType: case kCFNumberDoubleType: CFNumberGetValue(cfr, kCFNumberDoubleType, &d); +#if __IPHONE_OS_VERSION_MIN_REQUIRED >= __IPHONE_10_0 if (kCFCoreFoundationVersionNumber >= 1443.00) { r = (launch_data_t)xpc_double_create(d); } else { +#else + { +#endif // Not sure if this hangs, but added to be safe r = launch_data_alloc(LAUNCH_DATA_REAL); launch_data_set_real(r, d); |