summaryrefslogtreecommitdiff
path: root/src/glibext/gbinportion.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/glibext/gbinportion.c')
-rw-r--r--src/glibext/gbinportion.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/glibext/gbinportion.c b/src/glibext/gbinportion.c
index ab5fa6e..ff5ff7d 100644
--- a/src/glibext/gbinportion.c
+++ b/src/glibext/gbinportion.c
@@ -1216,14 +1216,17 @@ GBinPortion *g_binary_portion_find_at_pos(GBinPortion *portion, gint x, GdkRecta
static bool g_binary_portion_contains_vmpa(const GBinPortion *portion, const vmpa2t *addr)
{
bool result; /* Bilan à retourner */
+ const mrange_t *range; /* Emplacement de portion */
result = false;
- /* Portion non allouée en mémoire -> adresse nulle ; on écarte */
- if (get_virt_addr(get_mrange_addr(&portion->range)) == 0)
+ range = g_binary_portion_get_range(portion);
+
+ /* Portion non allouée en mémoire : on écarte */
+ if (!has_virt_addr(get_mrange_addr(range)))
goto not_found;
- result = mrange_contains_addr(&portion->range, addr);
+ result = mrange_contains_addr(range, addr);
not_found: