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

Add C callback in r_bp #946

Open
radare opened this issue May 19, 2014 · 9 comments
Open

Add C callback in r_bp #946

radare opened this issue May 19, 2014 · 9 comments
Labels
Milestone

Comments

@radare
Copy link
Collaborator

radare commented May 19, 2014

Used for tracing, breakpointing etc, and running code from inside the api. this will make the debugger loop async and we will require to add other callbacks to handle other exceptions instead of checking right after the waitpid() thing

@XVilka XVilka added RDebug and removed debug-info labels May 12, 2016
@XVilka XVilka added this to the 0.10.4 milestone May 12, 2016
@XVilka
Copy link
Contributor

XVilka commented May 12, 2016

@jduck your thoughts?

@jduck
Copy link
Contributor

jduck commented May 12, 2016

I'll take this into consideration surely.

@jduck
Copy link
Contributor

jduck commented May 16, 2016

After thinking some more about the issue, I think it's quite doable to have a callback function that gets called whenever a breakpoint is hit. That said, such a thing is only useful when using the r_debug API directly via C or bindings, right? In all likelihood the code would be executed right before "cmd.bp" is executed, so it wouldn't exactly be async. If something bad happens during processing of this breakpoint all bets would be off. For example, the user could kill the child or detach the inferior. If they do that, things are going to get really ugly when we attempt to proceed processing the breakpoint handling...

@radare
Copy link
Collaborator Author

radare commented May 16, 2016

yep. that callback will be only usable when using the api, but my idea was to use it interanlly because of those hairy corners

On 16 May 2016, at 20:52, Joshua J. Drake notifications@github.com wrote:

After thinking some more about the issue, I think it's quite doable to have a callback function that gets called whenever a breakpoint is hit. That said, such a thing is only useful when using the r_debug API directly via C or bindings, right? In all likelihood the code would be executed right before "cmd.bp" is executed, so it wouldn't exactly be async. If something bad happens during processing of this breakpoint all bets would be off. For example, the user could kill the child or detach the inferior. If they do that, things are going to get really ugly when we attempt to proceed processing the breakpoint handling...


You are receiving this because you authored the thread.
Reply to this email directly or view it on GitHub #946 (comment)

@jduck
Copy link
Contributor

jduck commented May 16, 2016

Luckily the handling of when breakpoints are hit is much simpler than continuing afterward. hehe.

@radare radare modified the milestones: 0.10.5, 0.10.4 Jun 25, 2016
@radare
Copy link
Collaborator Author

radare commented Jun 25, 2016

ping

@radare radare modified the milestones: 0.10.6, 0.10.5 Aug 8, 2016
@radare
Copy link
Collaborator Author

radare commented Aug 8, 2016

@jduck ping?

@jduck
Copy link
Contributor

jduck commented Aug 21, 2016

Sorry, no time lately :-/

@radare radare modified the milestones: 1.x, 0.10.6 Sep 21, 2016
@radare radare modified the milestones: 1.1.0, 1.0.0 Oct 8, 2016
@radare radare modified the milestones: 1.2.0, 1.1.0 Dec 9, 2016
@radare radare modified the milestones: 1.3.0, 1.2.0 Jan 13, 2017
@radare
Copy link
Collaborator Author

radare commented Jan 13, 2017

cc @leberus

@radare radare modified the milestones: 1.5.0, 1.3.0 Feb 28, 2017
@radare radare modified the milestones: 1.7.0, 1.5.0 May 20, 2017
@XVilka XVilka modified the milestones: 1.7.0, 1.8.0 Sep 28, 2017
@radare radare modified the milestones: 2.1.0, 2.3.0 Nov 24, 2017
@radare radare modified the milestones: 2.3.0, 9999 Jan 24, 2018
yossizap pushed a commit to yossizap/radare2 that referenced this issue Dec 30, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

5 participants