mirror of
https://github.com/kavishdevar/librepods.git
synced 2026-03-30 18:05:28 +00:00
disable DI hook and dependant functions
This commit is contained in:
@@ -265,9 +265,9 @@ static bool hookLibrary(const char* libname) {
|
||||
findSymbolOffset(decompressed,
|
||||
"l2c_fcr_chk_chan_modes");
|
||||
|
||||
uint64_t sdp_offset =
|
||||
findSymbolOffset(decompressed,
|
||||
"BTA_DmSetLocalDiRecord");
|
||||
// uint64_t sdp_offset =
|
||||
// findSymbolOffset(decompressed,
|
||||
// "BTA_DmSetLocalDiRecord");
|
||||
|
||||
if (chk_offset) {
|
||||
void* target =
|
||||
@@ -280,16 +280,16 @@ static bool hookLibrary(const char* libname) {
|
||||
LOGI("Hooked l2c_fcr_chk_chan_modes");
|
||||
}
|
||||
|
||||
if (sdp_offset) {
|
||||
void* target =
|
||||
reinterpret_cast<void*>(base + sdp_offset);
|
||||
|
||||
hook_func(target,
|
||||
(void*)fake_BTA_DmSetLocalDiRecord,
|
||||
(void**)&original_BTA_DmSetLocalDiRecord);
|
||||
|
||||
LOGI("Hooked BTA_DmSetLocalDiRecord");
|
||||
}
|
||||
// if (sdp_offset) {
|
||||
// void* target =
|
||||
// reinterpret_cast<void*>(base + sdp_offset);
|
||||
//
|
||||
// hook_func(target,
|
||||
// (void*)fake_BTA_DmSetLocalDiRecord,
|
||||
// (void**)&original_BTA_DmSetLocalDiRecord);
|
||||
//
|
||||
// LOGI("Hooked BTA_DmSetLocalDiRecord");
|
||||
// }
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -99,7 +99,7 @@ fun AccessibilitySettingsScreen(navController: NavController) {
|
||||
val isDarkTheme = isSystemInDarkTheme()
|
||||
val textColor = if (isDarkTheme) Color.White else Color.Black
|
||||
val aacpManager = remember { ServiceManager.getService()?.aacpManager }
|
||||
val isSdpOffsetAvailable = remember { mutableStateOf(true) } // always available rn, for testing without radare
|
||||
val isSdpOffsetAvailable = remember { mutableStateOf(false) } // always available rn, for testing without radare
|
||||
// remember { mutableStateOf(RadareOffsetFinder.isSdpOffsetAvailable()) }
|
||||
|
||||
val trackColor = if (isDarkTheme) Color(0xFFB3B3B3) else Color(0xFF929491)
|
||||
|
||||
@@ -267,10 +267,10 @@ fun AirPodsSettingsScreen(dev: BluetoothDevice?, service: AirPodsService,
|
||||
}
|
||||
// val actAsAppleDeviceHookEnabled = RadareOffsetFinder.isSdpOffsetAvailable()
|
||||
// if (actAsAppleDeviceHookEnabled) {
|
||||
item(key = "spacer_hearing_health") { Spacer(modifier = Modifier.height(32.dp)) }
|
||||
item(key = "hearing_health") {
|
||||
HearingHealthSettings(navController = navController)
|
||||
}
|
||||
// item(key = "spacer_hearing_health") { Spacer(modifier = Modifier.height(32.dp)) }
|
||||
// item(key = "hearing_health") {
|
||||
// HearingHealthSettings(navController = navController)
|
||||
// }
|
||||
// }
|
||||
|
||||
if (capabilities.contains(Capability.LISTENING_MODE)) {
|
||||
|
||||
@@ -90,7 +90,7 @@ fun TransparencySettingsScreen(navController: NavController) {
|
||||
val verticalScrollState = rememberScrollState()
|
||||
val attManager = ServiceManager.getService()?.attManager ?: return
|
||||
val aacpManager = remember { ServiceManager.getService()?.aacpManager }
|
||||
val isSdpOffsetAvailable = remember { mutableStateOf(true) } // always available rn, for testing without radare
|
||||
val isSdpOffsetAvailable = remember { mutableStateOf(false) } // always available rn, for testing without radare
|
||||
// remember { mutableStateOf(RadareOffsetFinder.isSdpOffsetAvailable()) }
|
||||
|
||||
val trackColor = if (isDarkTheme) Color(0xFFB3B3B3) else Color(0xFF929491)
|
||||
|
||||
Reference in New Issue
Block a user