3
0
mirror of https://github.com/hyprwm/Hyprland.git synced 2025-10-29 11:22:47 +00:00

functionHook: fix distance check

This commit is contained in:
Vaxry 2025-10-14 19:31:49 +01:00
parent ee5d05f0fc
commit f324a3a564
No known key found for this signature in database
GPG Key ID: 665806380871D640

View File

@ -172,8 +172,8 @@ bool CFunctionHook::hook() {
return false;
}
if (std::abs(rc<int64_t>(m_source) - rc<int64_t>(m_destination)) > 2000000000 /* 2 GB */) {
Debug::log(ERR, "[functionhook] failed, source and dest are over 2GB apart");
if (std::abs(rc<int64_t>(m_source) - rc<int64_t>(m_landTrampolineAddr)) > 2000000000 /* 2 GB */) {
Debug::log(ERR, "[functionhook] failed, source and trampo are over 2GB apart");
return false;
}