mirror of
https://github.com/radareorg/radare2.git
synced 2025-02-10 08:14:35 +00:00
![pancake](/assets/img/avatar_default.png)
* Honor null callback in r_cmd * Some enhacements in the r_config_description * Implement cmd.repeat and add two commands to handle it - . and .. (allow to handle pyew-like newline) * Add ia and ia* to show all binary information info - Use r_sys_cmd_str() instead of r_sys_cmd() - This fixes the bug of not able to interpret output of .i?* * Some random minor code simplifications * r_sys_getenv now returns an allocated buffer - Need some review to avoid memleaks
59 lines
1.4 KiB
Vala
59 lines
1.4 KiB
Vala
/* radare - LGPL - Copyright 2009-2011 pancake<nopcode.org> */
|
|
|
|
namespace Radare {
|
|
[Compact]
|
|
[CCode (cheader_filename="r_lib.h", cprefix="r_lib_", cname="struct r_lib_t", free_function="r_lib_free")]
|
|
public class RLib {
|
|
public RLib (string symname);
|
|
public bool close(string file);
|
|
public int opendir(string path);
|
|
public static string? path(string libname);
|
|
//public string types_get(int idx);
|
|
|
|
/* lowlevel api */
|
|
public static void* dl_open(string libname);
|
|
public void* dl_sym(string symname);
|
|
public static bool dl_close(void *handler);
|
|
public static bool dl_check_filename(string file);
|
|
/* handlers */
|
|
// we need delegates here (function pointerz)
|
|
// public bool add_handler(int type, string desc, /* */, void* user);
|
|
public bool del_handler(int type);
|
|
public Plugin get_handler(int type);
|
|
//public struct Struct { }
|
|
[Compact]
|
|
[CCode (cname="struct r_lib_handler_t*")]
|
|
public struct Plugin {
|
|
int type;
|
|
string desc;
|
|
void* user;
|
|
// constructor
|
|
// destructor
|
|
}
|
|
}
|
|
|
|
[Compact]
|
|
[CCode (cheader_filename="r_lib.h", cprefix="r_lib_struct_", cname="struct r_lib_struct_t", free_function="r_lib_free")]
|
|
public struct RLibStruct {
|
|
public RLibType foo;
|
|
public void *data;
|
|
}
|
|
|
|
[CCode (cprefix="R_LIB_TYPE_", cname="int")]
|
|
public enum RLibType {
|
|
IO,
|
|
DBG,
|
|
LANG,
|
|
ASM,
|
|
ANAL,
|
|
PARSE,
|
|
BIN,
|
|
BP,
|
|
SYSCALL,
|
|
FASTCALL,
|
|
CRYPTO,
|
|
CMD,
|
|
LAST
|
|
}
|
|
}
|