-
-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Segfault when saving project after 'aac' #5219
Comments
Its clearly a nullderef at var.c:472
|
I just wanted to note, that I've created this backtrace with @alvarofe -s pull request related to #5165, so the line numbers are valid in that version. But the bug was present before of that. Here is an older backtrace I've saved a week ago (but don't know the exact version of it).
|
var.c:478 is not a call to strdup..so my guess is that you are not using r2 from git. which version are you using?
|
I wrote it in my previous comment, but maybe I wasn't exact enough, so: The first backtrace is with #5218 This is The second is just there to show that the problem was not introduced by alvarofe-s pull request, it existed before (I saved the second trace around a week ago, don't know the exact version of it). |
Check again with my PR to see if the issue is fixed, is just a workaround, we should detect why the variable name or type is null though without the binary is hard to debug. I don't know if you could cook a test case for us if the binary can't be shared. |
@alvarofe The SEGFAULT disappeared after your patch. I've modified it to print more information:
I get this, after running
If I do If I just load the binary, and do an If anyone has an idea, how to track this down, i could try it, but unfortunatelly I can't share the binary. |
cc @oddcoder
|
well I didn't create |
I guess the issue is that when deleting vars some references are kept somwhere in |
Where does it segfault when using |
use the blind power of coverity
|
@oddcoder I think I could share the function, but thats why I tried that doing analysis on the function itself doesn't reproduce the problem.
Found another interesting problem with this executable. If I do
R_API void r_list_purge (RList *list) {
if (list) {
RListIter *it = list->head;
while (it) {
[*] RListIter *next = it->n;
r_list_delete (list, it);
it = next;
}
list->head = list->tail = NULL;
}
} In the marked line, the variable Unfortunatelly I can't share the binary, but will try to to find the cause of this second bug on weekend, maybe it will help with the first bug. Any advices welcome, where or how to look. |
this is important for the release |
This publicly available program produces the second bug (SEGFAULT when To reproduce:
|
reproduce, this is a regression introduced by @alvarofe but its a different segfalt to the first one, so there are 2 different issues here |
Yes, its two different ones. I hoped they are related and solving this could help solve the first one. Should I open another issue for this second segfault? |
Fixed here #5238 |
can we close this? |
I fixed one of the segfault the other i couldn't reproduce |
Closing it for now. Please @axt reopen in case it is reproducible |
Yes I think its plausible to close it. I can't share the binary. But even if I could share: What you could do is that in the message the workaround by @alvarofe prints out, you could add something like "this should not happen, please report it as an issue", or something, so maybe somone else will run into it, and share a testcase. |
@crowell ^ |
the slow performance is because of the patch from @ret2libc, its a known issue, but it is for correctness. @crowell and @ret2libc are working on a PR that fixes this problem. but im not sure if this patch will be available before the release that its actually delayed
|
I've an exe for which the
Ps
command SEGFAULTs, after runningaac
.Unfortunatelly I can't submit the binary. (+the
aac
runs 2 hours on this binary, so its not easy to test)I've made a
gdb
backtrace, if that helps:(seems strdup is called with a NULL pointer)
The text was updated successfully, but these errors were encountered: