This should be using the process instance retrieved within the function, and not g_current_process, otherwise this is potentially comparing iterators from unrelated vma_map instances (which is undefined behavior).
This should be using the process instance retrieved within the function, and not g_current_process, otherwise this is potentially comparing iterators from unrelated vma_map instances (which is undefined behavior).