mirror of
https://github.com/kavishdevar/librepods.git
synced 2026-04-03 19:59:03 +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,
|
findSymbolOffset(decompressed,
|
||||||
"l2c_fcr_chk_chan_modes");
|
"l2c_fcr_chk_chan_modes");
|
||||||
|
|
||||||
uint64_t sdp_offset =
|
// uint64_t sdp_offset =
|
||||||
findSymbolOffset(decompressed,
|
// findSymbolOffset(decompressed,
|
||||||
"BTA_DmSetLocalDiRecord");
|
// "BTA_DmSetLocalDiRecord");
|
||||||
|
|
||||||
if (chk_offset) {
|
if (chk_offset) {
|
||||||
void* target =
|
void* target =
|
||||||
@@ -280,16 +280,16 @@ static bool hookLibrary(const char* libname) {
|
|||||||
LOGI("Hooked l2c_fcr_chk_chan_modes");
|
LOGI("Hooked l2c_fcr_chk_chan_modes");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (sdp_offset) {
|
// if (sdp_offset) {
|
||||||
void* target =
|
// void* target =
|
||||||
reinterpret_cast<void*>(base + sdp_offset);
|
// reinterpret_cast<void*>(base + sdp_offset);
|
||||||
|
//
|
||||||
hook_func(target,
|
// hook_func(target,
|
||||||
(void*)fake_BTA_DmSetLocalDiRecord,
|
// (void*)fake_BTA_DmSetLocalDiRecord,
|
||||||
(void**)&original_BTA_DmSetLocalDiRecord);
|
// (void**)&original_BTA_DmSetLocalDiRecord);
|
||||||
|
//
|
||||||
LOGI("Hooked BTA_DmSetLocalDiRecord");
|
// LOGI("Hooked BTA_DmSetLocalDiRecord");
|
||||||
}
|
// }
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -99,7 +99,7 @@ fun AccessibilitySettingsScreen(navController: NavController) {
|
|||||||
val isDarkTheme = isSystemInDarkTheme()
|
val isDarkTheme = isSystemInDarkTheme()
|
||||||
val textColor = if (isDarkTheme) Color.White else Color.Black
|
val textColor = if (isDarkTheme) Color.White else Color.Black
|
||||||
val aacpManager = remember { ServiceManager.getService()?.aacpManager }
|
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()) }
|
// remember { mutableStateOf(RadareOffsetFinder.isSdpOffsetAvailable()) }
|
||||||
|
|
||||||
val trackColor = if (isDarkTheme) Color(0xFFB3B3B3) else Color(0xFF929491)
|
val trackColor = if (isDarkTheme) Color(0xFFB3B3B3) else Color(0xFF929491)
|
||||||
|
|||||||
@@ -267,10 +267,10 @@ fun AirPodsSettingsScreen(dev: BluetoothDevice?, service: AirPodsService,
|
|||||||
}
|
}
|
||||||
// val actAsAppleDeviceHookEnabled = RadareOffsetFinder.isSdpOffsetAvailable()
|
// val actAsAppleDeviceHookEnabled = RadareOffsetFinder.isSdpOffsetAvailable()
|
||||||
// if (actAsAppleDeviceHookEnabled) {
|
// if (actAsAppleDeviceHookEnabled) {
|
||||||
item(key = "spacer_hearing_health") { Spacer(modifier = Modifier.height(32.dp)) }
|
// item(key = "spacer_hearing_health") { Spacer(modifier = Modifier.height(32.dp)) }
|
||||||
item(key = "hearing_health") {
|
// item(key = "hearing_health") {
|
||||||
HearingHealthSettings(navController = navController)
|
// HearingHealthSettings(navController = navController)
|
||||||
}
|
// }
|
||||||
// }
|
// }
|
||||||
|
|
||||||
if (capabilities.contains(Capability.LISTENING_MODE)) {
|
if (capabilities.contains(Capability.LISTENING_MODE)) {
|
||||||
|
|||||||
@@ -90,7 +90,7 @@ fun TransparencySettingsScreen(navController: NavController) {
|
|||||||
val verticalScrollState = rememberScrollState()
|
val verticalScrollState = rememberScrollState()
|
||||||
val attManager = ServiceManager.getService()?.attManager ?: return
|
val attManager = ServiceManager.getService()?.attManager ?: return
|
||||||
val aacpManager = remember { ServiceManager.getService()?.aacpManager }
|
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()) }
|
// remember { mutableStateOf(RadareOffsetFinder.isSdpOffsetAvailable()) }
|
||||||
|
|
||||||
val trackColor = if (isDarkTheme) Color(0xFFB3B3B3) else Color(0xFF929491)
|
val trackColor = if (isDarkTheme) Color(0xFFB3B3B3) else Color(0xFF929491)
|
||||||
|
|||||||
Reference in New Issue
Block a user