summaryrefslogtreecommitdiff
path: root/src/cs2/iface.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/cs2/iface.h')
-rw-r--r--src/cs2/iface.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/cs2/iface.h b/src/cs2/iface.h
index be2137d..61cd91c 100644
--- a/src/cs2/iface.h
+++ b/src/cs2/iface.h
@@ -109,3 +109,17 @@ inline VECTOR<IFACE_ENTRY> iface_get_all( PROCESS64* p ) {
return entries;
}
+inline void iface_dump_to_file( PROCESS64* p ) {
+ VECTOR<IFACE_ENTRY> entries = iface_get_all( p );
+
+ static STR<9999999> output;
+ memset( output, 0, sizeof( output.data ) );
+
+ for( auto& it : entries ) {
+ U64 off = it.ptr - it.module;
+
+ sprintf( output, "%siface: %s @%s+0x%llx [0x%llx]\n", output.data, it.name.data, it.module_name.data, off, it.ptr );
+ }
+
+ u_write_to_file( output.data, "interfaces.txt" );
+} \ No newline at end of file