Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement r_io_submap_set_from and r_io_submap_set_to (siol eternal) #18476

Closed
condret opened this issue Mar 15, 2021 · 2 comments
Closed

Implement r_io_submap_set_from and r_io_submap_set_to (siol eternal) #18476

condret opened this issue Mar 15, 2021 · 2 comments

Comments

@condret
Copy link
Member

condret commented Mar 15, 2021

Description

Motivation

When inserting new submaps into a RIOBank, adjusting the boundaries of existing submaps is necessary, to ensure that submaps don't intersect.

Task

Implement r_io_submap_set_from and r_io_submap_set_to in libr/io/io_submap.c on siol_eternal branch:

R_API bool r_io_submap_set_from(RIOSubmap *sm, const ut64 from);
R_API bool r_io_submap_set_to(RIOSubmap *sm, const ut64 to);

Both functions shall return false, if sm is NULL or changing boundaries would result in negative interval size.
Else return true

@arv-77
Copy link

arv-77 commented May 9, 2021

@condret , do the functions also have to change the values of sm->itv.addr and sm->itv.size?

@condret
Copy link
Member Author

condret commented May 9, 2021

@arvindmuralie77 yes, sorry I didn't see your comment until now, I just implemented them

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants