radareorg/r2ghidra

pdg gives not c-style format

Closed this issue · 4 comments

Description

Please describe what are you missing or wanting to be improved

Hello. I am using r2ghidra after I installed r2 from source and r2ghidra from r2pm -ci r2ghidra.
When I type pdg in r2, it shows us not c-style source code rather similar to xml or something.
I have searched it but I could not find how to change the output format.

Provide images, ascii-art, test files and anything that may help us understand your request

<function>
<funcproto><return_type>void</return_type> main(void)</funcproto>

{
    <vardecl symref="0x400001000000001d">uint uVar1</vardecl>;
    <vardecl symref="0x400001000000001e">code cVar2</vardecl>;
    <vardecl symref="0x400001000000001f">int32_t iVar3</vardecl>;

// ...

Same issue here. I'm on the latest release versions of r2 and ghidra.

i can repro

Found and fixed 😄the regression was introduced in 700c2b0

actually that looks to me like an useful option to add instead of having a compile time define for debugging.