summaryrefslogtreecommitdiff
path: root/src/util.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/util.h')
-rw-r--r--src/util.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/util.h b/src/util.h
index c46ff72..705a778 100644
--- a/src/util.h
+++ b/src/util.h
@@ -19,6 +19,8 @@ extern ULONG u_thread_create( LPTHREAD_START_ROUTINE routine, void* param = 0 );
extern ULONG u_thread_create( HANDLE proc, LPTHREAD_START_ROUTINE routine, void* param = 0 );
extern void u_sleep( U64 ns );
+extern void u_bin_dump( void* data, U64 size, U32 stride = 8 );
+
template < U32 size >
struct STR {
STR() = default;
@@ -111,8 +113,8 @@ inline U8 u_set_debug_privilege() {
return 1;
}
-inline U8 u_binary_match( U8* code, U8* pattern, U32 size ) {
- for( U32 i = 0; i < size; ++i ) {
+inline U8 u_binary_match( U8* code, U8* pattern, U64 size ) {
+ for( U64 i = 0; i < size; ++i ) {
if( pattern[i] && (code[i] ^ pattern[i]) != 0 )
return 0;
}