Skip to content

Commit

Permalink
Fixed R key not working in custom graph (radareorg#10442)
Browse files Browse the repository at this point in the history
squash
  • Loading branch information
cyanpencil authored and soez committed Jun 21, 2018
1 parent 1267a30 commit a4fbbf7
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
6 changes: 3 additions & 3 deletions libr/core/graph.c
Expand Up @@ -4049,14 +4049,14 @@ R_API int r_core_visual_graph(RCore *core, RAGraph *g, RAnalFunction *_fcn, int
r_core_cmd (core, "sr PC", 0);
break;
case 'R':
if (!fcn) {
break;
}
if (r_config_get_i (core->config, "scr.randpal")) {
r_core_cmd0 (core, "ecr");
} else {
r_core_cmd0 (core, "ecn");
}
if (!fcn) {
break;
}
g->edgemode = r_config_get_i (core->config, "graph.edges");
get_bbupdate (g, core, fcn);
break;
Expand Down
4 changes: 1 addition & 3 deletions libr/core/linux_heap_glibc.c
Expand Up @@ -239,7 +239,7 @@ static bool GH(r_resolve_symbol)(RCore *core, GHT *symbol, const char *symname)
is_debug_file[4] = str_start_with (libc_ver_end, "/lib32/");
is_debug_file[5] = str_start_with (libc_ver_end, "/lib64/");

if (getenv("LD_PRELOAD")) {
if (r_sys_getenv ("LD_PRELOAD")) {
path = r_cons_input ("Is a custom library? Enter full path glibc: ");
if (r_file_exists (path)) {
goto found;
Expand All @@ -257,7 +257,6 @@ static bool GH(r_resolve_symbol)(RCore *core, GHT *symbol, const char *symname)
if (r_file_exists (path)) {
goto found;
}
free (path);
path = r_str_append (path, ".debug");
if (r_file_exists (path)) {
goto found;
Expand All @@ -267,7 +266,6 @@ static bool GH(r_resolve_symbol)(RCore *core, GHT *symbol, const char *symname)
r_file_is_directory ("/usr/lib/debug/.build-id")) {
get_hash_debug_file (libc_ver_end, hash, sizeof (hash) - 1);
libc_ver_end = hash;
free (path);
path = r_str_newf ("%s%s%s", dir_dbg, dir_build_id, libc_ver_end);
if (r_file_exists (path)) {
goto found;
Expand Down

0 comments on commit a4fbbf7

Please sign in to comment.