pub const STRING_FLAGS_LAST_IN_RULE: u32 = 4096;
pub const META_TYPE_INTEGER: u32 = 1;
pub const META_TYPE_STRING: u32 = 2;
pub const META_TYPE_BOOLEAN: u32 = 3;
pub const META_FLAGS_LAST_IN_RULE: u32 = 1;
pub const YARA_ERROR_LEVEL_ERROR: u32 = 0;
pub const YARA_ERROR_LEVEL_WARNING: u32 = 1;
pub const ERROR_SUCCESS: u32 = 0;
pub const ERROR_INSUFICIENT_MEMORY: u32 = 1;
pub const ERROR_INSUFFICIENT_MEMORY: u32 = 1;
pub const ERROR_COULD_NOT_ATTACH_TO_PROCESS: u32 = 2;
pub const ERROR_COULD_NOT_OPEN_FILE: u32 = 3;
pub const ERROR_COULD_NOT_MAP_FILE: u32 = 4;
pub const ERROR_INVALID_FILE: u32 = 6;
pub const ERROR_CORRUPT_FILE: u32 = 7;
pub const ERROR_UNSUPPORTED_FILE_VERSION: u32 = 8;
pub const ERROR_INVALID_REGULAR_EXPRESSION: u32 = 9;
pub const ERROR_INVALID_HEX_STRING: u32 = 10;
pub const ERROR_SYNTAX_ERROR: u32 = 11;
pub const ERROR_LOOP_NESTING_LIMIT_EXCEEDED: u32 = 12;
pub const ERROR_DUPLICATED_LOOP_IDENTIFIER: u32 = 13;
pub const ERROR_DUPLICATED_IDENTIFIER: u32 = 14;
pub const ERROR_DUPLICATED_TAG_IDENTIFIER: u32 = 15;
pub const ERROR_DUPLICATED_META_IDENTIFIER: u32 = 16;
pub const ERROR_DUPLICATED_STRING_IDENTIFIER: u32 = 17;
pub const ERROR_UNREFERENCED_STRING: u32 = 18;
pub const ERROR_UNDEFINED_STRING: u32 = 19;
pub const ERROR_UNDEFINED_IDENTIFIER: u32 = 20;
pub const ERROR_MISPLACED_ANONYMOUS_STRING: u32 = 21;
pub const ERROR_INCLUDES_CIRCULAR_REFERENCE: u32 = 22;
pub const ERROR_INCLUDE_DEPTH_EXCEEDED: u32 = 23;
pub const ERROR_WRONG_TYPE: u32 = 24;
pub const ERROR_EXEC_STACK_OVERFLOW: u32 = 25;
pub const ERROR_SCAN_TIMEOUT: u32 = 26;
pub const ERROR_TOO_MANY_SCAN_THREADS: u32 = 27;
pub const ERROR_CALLBACK_ERROR: u32 = 28;
pub const ERROR_INVALID_ARGUMENT: u32 = 29;
pub const ERROR_TOO_MANY_MATCHES: u32 = 30;
pub const ERROR_INTERNAL_FATAL_ERROR: u32 = 31;
pub const ERROR_NESTED_FOR_OF_LOOP: u32 = 32;
pub const ERROR_INVALID_FIELD_NAME: u32 = 33;
pub const ERROR_UNKNOWN_MODULE: u32 = 34;
pub const ERROR_NOT_A_STRUCTURE: u32 = 35;
pub const ERROR_NOT_INDEXABLE: u32 = 36;
pub const ERROR_NOT_A_FUNCTION: u32 = 37;
pub const ERROR_INVALID_FORMAT: u32 = 38;
pub const ERROR_TOO_MANY_ARGUMENTS: u32 = 39;
pub const ERROR_WRONG_ARGUMENTS: u32 = 40;
pub const ERROR_WRONG_RETURN_TYPE: u32 = 41;
pub const ERROR_DUPLICATED_STRUCTURE_MEMBER: u32 = 42;
pub const ERROR_EMPTY_STRING: u32 = 43;
pub const ERROR_DIVISION_BY_ZERO: u32 = 44;
pub const ERROR_REGULAR_EXPRESSION_TOO_LARGE: u32 = 45;
pub const ERROR_TOO_MANY_RE_FIBERS: u32 = 46;
pub const ERROR_COULD_NOT_READ_PROCESS_MEMORY: u32 = 47;
pub const ERROR_INVALID_EXTERNAL_VARIABLE_TYPE: u32 = 48;
pub const ERROR_REGULAR_EXPRESSION_TOO_COMPLEX: u32 = 49;
pub const ERROR_INVALID_MODULE_NAME: u32 = 50;
pub const ERROR_TOO_MANY_STRINGS: u32 = 51;
pub const ERROR_INTEGER_OVERFLOW: u32 = 52;
pub const ERROR_CALLBACK_REQUIRED: u32 = 53;
pub const ERROR_INVALID_OPERAND: u32 = 54;
pub const ERROR_COULD_NOT_READ_FILE: u32 = 55;
pub const ERROR_DUPLICATED_EXTERNAL_VARIABLE: u32 = 56;
pub const ERROR_INVALID_MODULE_DATA: u32 = 57;
pub const ERROR_WRITING_FILE: u32 = 58;
pub const ERROR_INVALID_MODIFIER: u32 = 59;
pub const ERROR_DUPLICATED_MODIFIER: u32 = 60;
pub const ERROR_BLOCK_NOT_READY: u32 = 61;
pub const CALLBACK_MSG_RULE_MATCHING: u32 = 1;
pub const CALLBACK_MSG_RULE_NOT_MATCHING: u32 = 2;
pub const CALLBACK_MSG_SCAN_FINISHED: u32 = 3;
pub const CALLBACK_MSG_IMPORT_MODULE: u32 = 4;
pub const CALLBACK_MSG_MODULE_IMPORTED: u32 = 5;
pub const CALLBACK_MSG_TOO_MANY_MATCHES: u32 = 6;
pub const CALLBACK_CONTINUE: u32 = 0;
pub const CALLBACK_ABORT: u32 = 1;
pub const CALLBACK_ERROR: u32 = 2;
pub const SCAN_FLAGS_FAST_MODE: u32 = 1;
pub const SCAN_FLAGS_PROCESS_MEMORY: u32 = 2;
pub const SCAN_FLAGS_NO_TRYCATCH: u32 = 4;
pub const SCAN_FLAGS_REPORT_RULES_MATCHING: u32 = 8;
pub const SCAN_FLAGS_REPORT_RULES_NOT_MATCHING: u32 = 16;
pub type size_t = ::std::os::raw::c_ulong;
pub type __uint8_t = ::std::os::raw::c_uchar;
pub type __uint16_t = ::std::os::raw::c_ushort;
pub type __int32_t = ::std::os::raw::c_int;
pub type __uint32_t = ::std::os::raw::c_uint;
pub type __int64_t = ::std::os::raw::c_long;
pub type __uint64_t = ::std::os::raw::c_ulong;
pub type __off_t = ::std::os::raw::c_long;
pub type __off64_t = ::std::os::raw::c_long;
pub type __time_t = ::std::os::raw::c_long;
pub type __suseconds_t = ::std::os::raw::c_long;
pub type __syscall_slong_t = ::std::os::raw::c_long;
pub type FILE = _IO_FILE;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _IO_marker {
_unused: [u8; 0],
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _IO_codecvt {
_unused: [u8; 0],
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _IO_wide_data {
_unused: [u8; 0],
}
pub type _IO_lock_t = ::std::os::raw::c_void;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _IO_FILE {
pub _flags: ::std::os::raw::c_int,
pub _IO_read_ptr: *mut ::std::os::raw::c_char,
pub _IO_read_end: *mut ::std::os::raw::c_char,
pub _IO_read_base: *mut ::std::os::raw::c_char,
pub _IO_write_base: *mut ::std::os::raw::c_char,
pub _IO_write_ptr: *mut ::std::os::raw::c_char,
pub _IO_write_end: *mut ::std::os::raw::c_char,
pub _IO_buf_base: *mut ::std::os::raw::c_char,
pub _IO_buf_end: *mut ::std::os::raw::c_char,
pub _IO_save_base: *mut ::std::os::raw::c_char,
pub _IO_backup_base: *mut ::std::os::raw::c_char,
pub _IO_save_end: *mut ::std::os::raw::c_char,
pub _markers: *mut _IO_marker,
pub _chain: *mut _IO_FILE,
pub _fileno: ::std::os::raw::c_int,
pub _flags2: ::std::os::raw::c_int,
pub _old_offset: __off_t,
pub _cur_column: ::std::os::raw::c_ushort,
pub _vtable_offset: ::std::os::raw::c_schar,
pub _shortbuf: [::std::os::raw::c_char; 1usize],
pub _lock: *mut _IO_lock_t,
pub _offset: __off64_t,
pub _codecvt: *mut _IO_codecvt,
pub _wide_data: *mut _IO_wide_data,
pub _freeres_list: *mut _IO_FILE,
pub _freeres_buf: *mut ::std::os::raw::c_void,
pub __pad5: size_t,
pub _mode: ::std::os::raw::c_int,
pub _unused2: [::std::os::raw::c_char; 20usize],
}
#[test]
fn bindgen_test_layout__IO_FILE() {
assert_eq!(
::std::mem::size_of::<_IO_FILE>(),
216usize,
concat!("Size of: ", stringify!(_IO_FILE))
);
assert_eq!(
::std::mem::align_of::<_IO_FILE>(),
8usize,
concat!("Alignment of ", stringify!(_IO_FILE))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._flags as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_flags)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._IO_read_ptr as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_IO_read_ptr)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._IO_read_end as *const _ as usize },
16usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_IO_read_end)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._IO_read_base as *const _ as usize },
24usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_IO_read_base)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._IO_write_base as *const _ as usize },
32usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_IO_write_base)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._IO_write_ptr as *const _ as usize },
40usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_IO_write_ptr)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._IO_write_end as *const _ as usize },
48usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_IO_write_end)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._IO_buf_base as *const _ as usize },
56usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_IO_buf_base)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._IO_buf_end as *const _ as usize },
64usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_IO_buf_end)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._IO_save_base as *const _ as usize },
72usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_IO_save_base)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._IO_backup_base as *const _ as usize },
80usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_IO_backup_base)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._IO_save_end as *const _ as usize },
88usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_IO_save_end)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._markers as *const _ as usize },
96usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_markers)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._chain as *const _ as usize },
104usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_chain)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._fileno as *const _ as usize },
112usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_fileno)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._flags2 as *const _ as usize },
116usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_flags2)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._old_offset as *const _ as usize },
120usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_old_offset)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._cur_column as *const _ as usize },
128usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_cur_column)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._vtable_offset as *const _ as usize },
130usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_vtable_offset)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._shortbuf as *const _ as usize },
131usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_shortbuf)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._lock as *const _ as usize },
136usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_lock)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._offset as *const _ as usize },
144usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_offset)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._codecvt as *const _ as usize },
152usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_codecvt)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._wide_data as *const _ as usize },
160usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_wide_data)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._freeres_list as *const _ as usize },
168usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_freeres_list)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._freeres_buf as *const _ as usize },
176usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_freeres_buf)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>())).__pad5 as *const _ as usize },
184usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(__pad5)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._mode as *const _ as usize },
192usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_mode)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_IO_FILE>()))._unused2 as *const _ as usize },
196usize,
concat!(
"Offset of field: ",
stringify!(_IO_FILE),
"::",
stringify!(_unused2)
)
);
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct timeval {
pub tv_sec: __time_t,
pub tv_usec: __suseconds_t,
}
#[test]
fn bindgen_test_layout_timeval() {
assert_eq!(
::std::mem::size_of::<timeval>(),
16usize,
concat!("Size of: ", stringify!(timeval))
);
assert_eq!(
::std::mem::align_of::<timeval>(),
8usize,
concat!("Alignment of ", stringify!(timeval))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<timeval>())).tv_sec as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(timeval),
"::",
stringify!(tv_sec)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<timeval>())).tv_usec as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(timeval),
"::",
stringify!(tv_usec)
)
);
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct timespec {
pub tv_sec: __time_t,
pub tv_nsec: __syscall_slong_t,
}
#[test]
fn bindgen_test_layout_timespec() {
assert_eq!(
::std::mem::size_of::<timespec>(),
16usize,
concat!("Size of: ", stringify!(timespec))
);
assert_eq!(
::std::mem::align_of::<timespec>(),
8usize,
concat!("Alignment of ", stringify!(timespec))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<timespec>())).tv_sec as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(timespec),
"::",
stringify!(tv_sec)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<timespec>())).tv_nsec as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(timespec),
"::",
stringify!(tv_nsec)
)
);
}
pub type YR_STREAM_READ_FUNC = ::std::option::Option<
unsafe extern "C" fn(
ptr: *mut ::std::os::raw::c_void,
size: size_t,
count: size_t,
user_data: *mut ::std::os::raw::c_void,
) -> size_t,
>;
pub type YR_STREAM_WRITE_FUNC = ::std::option::Option<
unsafe extern "C" fn(
ptr: *const ::std::os::raw::c_void,
size: size_t,
count: size_t,
user_data: *mut ::std::os::raw::c_void,
) -> size_t,
>;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _YR_STREAM {
pub user_data: *mut ::std::os::raw::c_void,
pub read: YR_STREAM_READ_FUNC,
pub write: YR_STREAM_WRITE_FUNC,
}
#[test]
fn bindgen_test_layout__YR_STREAM() {
assert_eq!(
::std::mem::size_of::<_YR_STREAM>(),
24usize,
concat!("Size of: ", stringify!(_YR_STREAM))
);
assert_eq!(
::std::mem::align_of::<_YR_STREAM>(),
8usize,
concat!("Alignment of ", stringify!(_YR_STREAM))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_YR_STREAM>())).user_data as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(_YR_STREAM),
"::",
stringify!(user_data)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_YR_STREAM>())).read as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(_YR_STREAM),
"::",
stringify!(read)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_YR_STREAM>())).write as *const _ as usize },
16usize,
concat!(
"Offset of field: ",
stringify!(_YR_STREAM),
"::",
stringify!(write)
)
);
}
pub type YR_STREAM = _YR_STREAM;
pub type yr_arena_off_t = u32;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct YR_ARENA_REF {
pub buffer_id: u32,
pub offset: yr_arena_off_t,
}
#[test]
fn bindgen_test_layout_YR_ARENA_REF() {
assert_eq!(
::std::mem::size_of::<YR_ARENA_REF>(),
8usize,
concat!("Size of: ", stringify!(YR_ARENA_REF))
);
assert_eq!(
::std::mem::align_of::<YR_ARENA_REF>(),
4usize,
concat!("Alignment of ", stringify!(YR_ARENA_REF))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_ARENA_REF>())).buffer_id as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_ARENA_REF),
"::",
stringify!(buffer_id)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_ARENA_REF>())).offset as *const _ as usize },
4usize,
concat!(
"Offset of field: ",
stringify!(YR_ARENA_REF),
"::",
stringify!(offset)
)
);
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct YR_ARENA_BUFFER {
pub data: *mut u8,
pub size: size_t,
pub used: size_t,
}
#[test]
fn bindgen_test_layout_YR_ARENA_BUFFER() {
assert_eq!(
::std::mem::size_of::<YR_ARENA_BUFFER>(),
24usize,
concat!("Size of: ", stringify!(YR_ARENA_BUFFER))
);
assert_eq!(
::std::mem::align_of::<YR_ARENA_BUFFER>(),
8usize,
concat!("Alignment of ", stringify!(YR_ARENA_BUFFER))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_ARENA_BUFFER>())).data as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_ARENA_BUFFER),
"::",
stringify!(data)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_ARENA_BUFFER>())).size as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(YR_ARENA_BUFFER),
"::",
stringify!(size)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_ARENA_BUFFER>())).used as *const _ as usize },
16usize,
concat!(
"Offset of field: ",
stringify!(YR_ARENA_BUFFER),
"::",
stringify!(used)
)
);
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct YR_RELOC {
pub buffer_id: u32,
pub offset: yr_arena_off_t,
pub next: *mut YR_RELOC,
}
#[test]
fn bindgen_test_layout_YR_RELOC() {
assert_eq!(
::std::mem::size_of::<YR_RELOC>(),
16usize,
concat!("Size of: ", stringify!(YR_RELOC))
);
assert_eq!(
::std::mem::align_of::<YR_RELOC>(),
8usize,
concat!("Alignment of ", stringify!(YR_RELOC))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RELOC>())).buffer_id as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_RELOC),
"::",
stringify!(buffer_id)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RELOC>())).offset as *const _ as usize },
4usize,
concat!(
"Offset of field: ",
stringify!(YR_RELOC),
"::",
stringify!(offset)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RELOC>())).next as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(YR_RELOC),
"::",
stringify!(next)
)
);
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct YR_ARENA {
pub xrefs: u32,
pub num_buffers: u32,
pub buffers: [YR_ARENA_BUFFER; 16usize],
pub initial_buffer_size: size_t,
pub reloc_list_head: *mut YR_RELOC,
pub reloc_list_tail: *mut YR_RELOC,
}
#[test]
fn bindgen_test_layout_YR_ARENA() {
assert_eq!(
::std::mem::size_of::<YR_ARENA>(),
416usize,
concat!("Size of: ", stringify!(YR_ARENA))
);
assert_eq!(
::std::mem::align_of::<YR_ARENA>(),
8usize,
concat!("Alignment of ", stringify!(YR_ARENA))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_ARENA>())).xrefs as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_ARENA),
"::",
stringify!(xrefs)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_ARENA>())).num_buffers as *const _ as usize },
4usize,
concat!(
"Offset of field: ",
stringify!(YR_ARENA),
"::",
stringify!(num_buffers)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_ARENA>())).buffers as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(YR_ARENA),
"::",
stringify!(buffers)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_ARENA>())).initial_buffer_size as *const _ as usize },
392usize,
concat!(
"Offset of field: ",
stringify!(YR_ARENA),
"::",
stringify!(initial_buffer_size)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_ARENA>())).reloc_list_head as *const _ as usize },
400usize,
concat!(
"Offset of field: ",
stringify!(YR_ARENA),
"::",
stringify!(reloc_list_head)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_ARENA>())).reloc_list_tail as *const _ as usize },
408usize,
concat!(
"Offset of field: ",
stringify!(YR_ARENA),
"::",
stringify!(reloc_list_tail)
)
);
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _YR_HASH_TABLE_ENTRY {
pub key: *mut ::std::os::raw::c_void,
pub key_length: size_t,
pub ns: *mut ::std::os::raw::c_char,
pub value: *mut ::std::os::raw::c_void,
pub next: *mut _YR_HASH_TABLE_ENTRY,
}
#[test]
fn bindgen_test_layout__YR_HASH_TABLE_ENTRY() {
assert_eq!(
::std::mem::size_of::<_YR_HASH_TABLE_ENTRY>(),
40usize,
concat!("Size of: ", stringify!(_YR_HASH_TABLE_ENTRY))
);
assert_eq!(
::std::mem::align_of::<_YR_HASH_TABLE_ENTRY>(),
8usize,
concat!("Alignment of ", stringify!(_YR_HASH_TABLE_ENTRY))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_YR_HASH_TABLE_ENTRY>())).key as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(_YR_HASH_TABLE_ENTRY),
"::",
stringify!(key)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_YR_HASH_TABLE_ENTRY>())).key_length as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(_YR_HASH_TABLE_ENTRY),
"::",
stringify!(key_length)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_YR_HASH_TABLE_ENTRY>())).ns as *const _ as usize },
16usize,
concat!(
"Offset of field: ",
stringify!(_YR_HASH_TABLE_ENTRY),
"::",
stringify!(ns)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_YR_HASH_TABLE_ENTRY>())).value as *const _ as usize },
24usize,
concat!(
"Offset of field: ",
stringify!(_YR_HASH_TABLE_ENTRY),
"::",
stringify!(value)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_YR_HASH_TABLE_ENTRY>())).next as *const _ as usize },
32usize,
concat!(
"Offset of field: ",
stringify!(_YR_HASH_TABLE_ENTRY),
"::",
stringify!(next)
)
);
}
pub type YR_HASH_TABLE_ENTRY = _YR_HASH_TABLE_ENTRY;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _YR_HASH_TABLE {
pub size: ::std::os::raw::c_int,
pub buckets: [*mut YR_HASH_TABLE_ENTRY; 1usize],
}
#[test]
fn bindgen_test_layout__YR_HASH_TABLE() {
assert_eq!(
::std::mem::size_of::<_YR_HASH_TABLE>(),
16usize,
concat!("Size of: ", stringify!(_YR_HASH_TABLE))
);
assert_eq!(
::std::mem::align_of::<_YR_HASH_TABLE>(),
8usize,
concat!("Alignment of ", stringify!(_YR_HASH_TABLE))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_YR_HASH_TABLE>())).size as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(_YR_HASH_TABLE),
"::",
stringify!(size)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<_YR_HASH_TABLE>())).buckets as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(_YR_HASH_TABLE),
"::",
stringify!(buckets)
)
);
}
pub type YR_HASH_TABLE = _YR_HASH_TABLE;
#[repr(C)]
#[derive(Copy, Clone)]
pub struct _YR_STOPWATCH {
pub __bindgen_anon_1: _YR_STOPWATCH__bindgen_ty_1,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union _YR_STOPWATCH__bindgen_ty_1 {
pub tv_start: timeval,
pub ts_start: timespec,
}
#[test]
fn bindgen_test_layout__YR_STOPWATCH__bindgen_ty_1() {
assert_eq!(
::std::mem::size_of::<_YR_STOPWATCH__bindgen_ty_1>(),
16usize,
concat!("Size of: ", stringify!(_YR_STOPWATCH__bindgen_ty_1))
);
assert_eq!(
::std::mem::align_of::<_YR_STOPWATCH__bindgen_ty_1>(),
8usize,
concat!("Alignment of ", stringify!(_YR_STOPWATCH__bindgen_ty_1))
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<_YR_STOPWATCH__bindgen_ty_1>())).tv_start as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(_YR_STOPWATCH__bindgen_ty_1),
"::",
stringify!(tv_start)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<_YR_STOPWATCH__bindgen_ty_1>())).ts_start as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(_YR_STOPWATCH__bindgen_ty_1),
"::",
stringify!(ts_start)
)
);
}
#[test]
fn bindgen_test_layout__YR_STOPWATCH() {
assert_eq!(
::std::mem::size_of::<_YR_STOPWATCH>(),
16usize,
concat!("Size of: ", stringify!(_YR_STOPWATCH))
);
assert_eq!(
::std::mem::align_of::<_YR_STOPWATCH>(),
8usize,
concat!("Alignment of ", stringify!(_YR_STOPWATCH))
);
}
pub type YR_STOPWATCH = _YR_STOPWATCH;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct YR_NOTEBOOK {
_unused: [u8; 0],
}
pub type YR_AC_TRANSITION = u32;
#[repr(C)]
#[derive(Copy, Clone)]
pub struct YR_NAMESPACE {
pub __bindgen_anon_1: YR_NAMESPACE__bindgen_ty_1,
pub idx: u32,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union YR_NAMESPACE__bindgen_ty_1 {
pub name: *const ::std::os::raw::c_char,
pub name_: YR_ARENA_REF,
}
#[test]
fn bindgen_test_layout_YR_NAMESPACE__bindgen_ty_1() {
assert_eq!(
::std::mem::size_of::<YR_NAMESPACE__bindgen_ty_1>(),
8usize,
concat!("Size of: ", stringify!(YR_NAMESPACE__bindgen_ty_1))
);
assert_eq!(
::std::mem::align_of::<YR_NAMESPACE__bindgen_ty_1>(),
8usize,
concat!("Alignment of ", stringify!(YR_NAMESPACE__bindgen_ty_1))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_NAMESPACE__bindgen_ty_1>())).name as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_NAMESPACE__bindgen_ty_1),
"::",
stringify!(name)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_NAMESPACE__bindgen_ty_1>())).name_ as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_NAMESPACE__bindgen_ty_1),
"::",
stringify!(name_)
)
);
}
#[test]
fn bindgen_test_layout_YR_NAMESPACE() {
assert_eq!(
::std::mem::size_of::<YR_NAMESPACE>(),
16usize,
concat!("Size of: ", stringify!(YR_NAMESPACE))
);
assert_eq!(
::std::mem::align_of::<YR_NAMESPACE>(),
8usize,
concat!("Alignment of ", stringify!(YR_NAMESPACE))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_NAMESPACE>())).idx as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(YR_NAMESPACE),
"::",
stringify!(idx)
)
);
}
#[repr(C)]
#[derive(Copy, Clone)]
pub struct YR_META {
pub __bindgen_anon_1: YR_META__bindgen_ty_1,
pub __bindgen_anon_2: YR_META__bindgen_ty_2,
pub integer: i64,
pub type_: i32,
pub flags: i32,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union YR_META__bindgen_ty_1 {
pub identifier: *const ::std::os::raw::c_char,
pub identifier_: YR_ARENA_REF,
}
#[test]
fn bindgen_test_layout_YR_META__bindgen_ty_1() {
assert_eq!(
::std::mem::size_of::<YR_META__bindgen_ty_1>(),
8usize,
concat!("Size of: ", stringify!(YR_META__bindgen_ty_1))
);
assert_eq!(
::std::mem::align_of::<YR_META__bindgen_ty_1>(),
8usize,
concat!("Alignment of ", stringify!(YR_META__bindgen_ty_1))
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_META__bindgen_ty_1>())).identifier as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_META__bindgen_ty_1),
"::",
stringify!(identifier)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_META__bindgen_ty_1>())).identifier_ as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_META__bindgen_ty_1),
"::",
stringify!(identifier_)
)
);
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union YR_META__bindgen_ty_2 {
pub string: *const ::std::os::raw::c_char,
pub string_: YR_ARENA_REF,
}
#[test]
fn bindgen_test_layout_YR_META__bindgen_ty_2() {
assert_eq!(
::std::mem::size_of::<YR_META__bindgen_ty_2>(),
8usize,
concat!("Size of: ", stringify!(YR_META__bindgen_ty_2))
);
assert_eq!(
::std::mem::align_of::<YR_META__bindgen_ty_2>(),
8usize,
concat!("Alignment of ", stringify!(YR_META__bindgen_ty_2))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_META__bindgen_ty_2>())).string as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_META__bindgen_ty_2),
"::",
stringify!(string)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_META__bindgen_ty_2>())).string_ as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_META__bindgen_ty_2),
"::",
stringify!(string_)
)
);
}
#[test]
fn bindgen_test_layout_YR_META() {
assert_eq!(
::std::mem::size_of::<YR_META>(),
32usize,
concat!("Size of: ", stringify!(YR_META))
);
assert_eq!(
::std::mem::align_of::<YR_META>(),
8usize,
concat!("Alignment of ", stringify!(YR_META))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_META>())).integer as *const _ as usize },
16usize,
concat!(
"Offset of field: ",
stringify!(YR_META),
"::",
stringify!(integer)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_META>())).type_ as *const _ as usize },
24usize,
concat!(
"Offset of field: ",
stringify!(YR_META),
"::",
stringify!(type_)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_META>())).flags as *const _ as usize },
28usize,
concat!(
"Offset of field: ",
stringify!(YR_META),
"::",
stringify!(flags)
)
);
}
#[repr(C)]
#[derive(Copy, Clone)]
pub struct YR_STRING {
pub flags: u32,
pub idx: u32,
pub fixed_offset: i64,
pub rule_idx: u32,
pub length: i32,
pub __bindgen_anon_1: YR_STRING__bindgen_ty_1,
pub __bindgen_anon_2: YR_STRING__bindgen_ty_2,
pub chain_gap_min: i32,
pub chain_gap_max: i32,
pub __bindgen_anon_3: YR_STRING__bindgen_ty_3,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union YR_STRING__bindgen_ty_1 {
pub string: *mut u8,
pub string_: YR_ARENA_REF,
}
#[test]
fn bindgen_test_layout_YR_STRING__bindgen_ty_1() {
assert_eq!(
::std::mem::size_of::<YR_STRING__bindgen_ty_1>(),
8usize,
concat!("Size of: ", stringify!(YR_STRING__bindgen_ty_1))
);
assert_eq!(
::std::mem::align_of::<YR_STRING__bindgen_ty_1>(),
8usize,
concat!("Alignment of ", stringify!(YR_STRING__bindgen_ty_1))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_STRING__bindgen_ty_1>())).string as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_STRING__bindgen_ty_1),
"::",
stringify!(string)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_STRING__bindgen_ty_1>())).string_ as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_STRING__bindgen_ty_1),
"::",
stringify!(string_)
)
);
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union YR_STRING__bindgen_ty_2 {
pub chained_to: *mut YR_STRING,
pub chained_to_: YR_ARENA_REF,
}
#[test]
fn bindgen_test_layout_YR_STRING__bindgen_ty_2() {
assert_eq!(
::std::mem::size_of::<YR_STRING__bindgen_ty_2>(),
8usize,
concat!("Size of: ", stringify!(YR_STRING__bindgen_ty_2))
);
assert_eq!(
::std::mem::align_of::<YR_STRING__bindgen_ty_2>(),
8usize,
concat!("Alignment of ", stringify!(YR_STRING__bindgen_ty_2))
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_STRING__bindgen_ty_2>())).chained_to as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_STRING__bindgen_ty_2),
"::",
stringify!(chained_to)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_STRING__bindgen_ty_2>())).chained_to_ as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_STRING__bindgen_ty_2),
"::",
stringify!(chained_to_)
)
);
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union YR_STRING__bindgen_ty_3 {
pub identifier: *const ::std::os::raw::c_char,
pub identifier_: YR_ARENA_REF,
}
#[test]
fn bindgen_test_layout_YR_STRING__bindgen_ty_3() {
assert_eq!(
::std::mem::size_of::<YR_STRING__bindgen_ty_3>(),
8usize,
concat!("Size of: ", stringify!(YR_STRING__bindgen_ty_3))
);
assert_eq!(
::std::mem::align_of::<YR_STRING__bindgen_ty_3>(),
8usize,
concat!("Alignment of ", stringify!(YR_STRING__bindgen_ty_3))
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_STRING__bindgen_ty_3>())).identifier as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_STRING__bindgen_ty_3),
"::",
stringify!(identifier)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_STRING__bindgen_ty_3>())).identifier_ as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_STRING__bindgen_ty_3),
"::",
stringify!(identifier_)
)
);
}
#[test]
fn bindgen_test_layout_YR_STRING() {
assert_eq!(
::std::mem::size_of::<YR_STRING>(),
56usize,
concat!("Size of: ", stringify!(YR_STRING))
);
assert_eq!(
::std::mem::align_of::<YR_STRING>(),
8usize,
concat!("Alignment of ", stringify!(YR_STRING))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_STRING>())).flags as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_STRING),
"::",
stringify!(flags)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_STRING>())).idx as *const _ as usize },
4usize,
concat!(
"Offset of field: ",
stringify!(YR_STRING),
"::",
stringify!(idx)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_STRING>())).fixed_offset as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(YR_STRING),
"::",
stringify!(fixed_offset)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_STRING>())).rule_idx as *const _ as usize },
16usize,
concat!(
"Offset of field: ",
stringify!(YR_STRING),
"::",
stringify!(rule_idx)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_STRING>())).length as *const _ as usize },
20usize,
concat!(
"Offset of field: ",
stringify!(YR_STRING),
"::",
stringify!(length)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_STRING>())).chain_gap_min as *const _ as usize },
40usize,
concat!(
"Offset of field: ",
stringify!(YR_STRING),
"::",
stringify!(chain_gap_min)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_STRING>())).chain_gap_max as *const _ as usize },
44usize,
concat!(
"Offset of field: ",
stringify!(YR_STRING),
"::",
stringify!(chain_gap_max)
)
);
}
#[repr(C)]
#[derive(Copy, Clone)]
pub struct YR_RULE {
pub flags: i32,
pub num_atoms: i32,
pub __bindgen_anon_1: YR_RULE__bindgen_ty_1,
pub __bindgen_anon_2: YR_RULE__bindgen_ty_2,
pub __bindgen_anon_3: YR_RULE__bindgen_ty_3,
pub __bindgen_anon_4: YR_RULE__bindgen_ty_4,
pub __bindgen_anon_5: YR_RULE__bindgen_ty_5,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union YR_RULE__bindgen_ty_1 {
pub identifier: *const ::std::os::raw::c_char,
pub identifier_: YR_ARENA_REF,
}
#[test]
fn bindgen_test_layout_YR_RULE__bindgen_ty_1() {
assert_eq!(
::std::mem::size_of::<YR_RULE__bindgen_ty_1>(),
8usize,
concat!("Size of: ", stringify!(YR_RULE__bindgen_ty_1))
);
assert_eq!(
::std::mem::align_of::<YR_RULE__bindgen_ty_1>(),
8usize,
concat!("Alignment of ", stringify!(YR_RULE__bindgen_ty_1))
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_RULE__bindgen_ty_1>())).identifier as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_RULE__bindgen_ty_1),
"::",
stringify!(identifier)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_RULE__bindgen_ty_1>())).identifier_ as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_RULE__bindgen_ty_1),
"::",
stringify!(identifier_)
)
);
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union YR_RULE__bindgen_ty_2 {
pub tags: *const ::std::os::raw::c_char,
pub tags_: YR_ARENA_REF,
}
#[test]
fn bindgen_test_layout_YR_RULE__bindgen_ty_2() {
assert_eq!(
::std::mem::size_of::<YR_RULE__bindgen_ty_2>(),
8usize,
concat!("Size of: ", stringify!(YR_RULE__bindgen_ty_2))
);
assert_eq!(
::std::mem::align_of::<YR_RULE__bindgen_ty_2>(),
8usize,
concat!("Alignment of ", stringify!(YR_RULE__bindgen_ty_2))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULE__bindgen_ty_2>())).tags as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_RULE__bindgen_ty_2),
"::",
stringify!(tags)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULE__bindgen_ty_2>())).tags_ as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_RULE__bindgen_ty_2),
"::",
stringify!(tags_)
)
);
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union YR_RULE__bindgen_ty_3 {
pub metas: *mut YR_META,
pub metas_: YR_ARENA_REF,
}
#[test]
fn bindgen_test_layout_YR_RULE__bindgen_ty_3() {
assert_eq!(
::std::mem::size_of::<YR_RULE__bindgen_ty_3>(),
8usize,
concat!("Size of: ", stringify!(YR_RULE__bindgen_ty_3))
);
assert_eq!(
::std::mem::align_of::<YR_RULE__bindgen_ty_3>(),
8usize,
concat!("Alignment of ", stringify!(YR_RULE__bindgen_ty_3))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULE__bindgen_ty_3>())).metas as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_RULE__bindgen_ty_3),
"::",
stringify!(metas)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULE__bindgen_ty_3>())).metas_ as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_RULE__bindgen_ty_3),
"::",
stringify!(metas_)
)
);
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union YR_RULE__bindgen_ty_4 {
pub strings: *mut YR_STRING,
pub strings_: YR_ARENA_REF,
}
#[test]
fn bindgen_test_layout_YR_RULE__bindgen_ty_4() {
assert_eq!(
::std::mem::size_of::<YR_RULE__bindgen_ty_4>(),
8usize,
concat!("Size of: ", stringify!(YR_RULE__bindgen_ty_4))
);
assert_eq!(
::std::mem::align_of::<YR_RULE__bindgen_ty_4>(),
8usize,
concat!("Alignment of ", stringify!(YR_RULE__bindgen_ty_4))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULE__bindgen_ty_4>())).strings as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_RULE__bindgen_ty_4),
"::",
stringify!(strings)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULE__bindgen_ty_4>())).strings_ as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_RULE__bindgen_ty_4),
"::",
stringify!(strings_)
)
);
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union YR_RULE__bindgen_ty_5 {
pub ns: *mut YR_NAMESPACE,
pub ns_: YR_ARENA_REF,
}
#[test]
fn bindgen_test_layout_YR_RULE__bindgen_ty_5() {
assert_eq!(
::std::mem::size_of::<YR_RULE__bindgen_ty_5>(),
8usize,
concat!("Size of: ", stringify!(YR_RULE__bindgen_ty_5))
);
assert_eq!(
::std::mem::align_of::<YR_RULE__bindgen_ty_5>(),
8usize,
concat!("Alignment of ", stringify!(YR_RULE__bindgen_ty_5))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULE__bindgen_ty_5>())).ns as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_RULE__bindgen_ty_5),
"::",
stringify!(ns)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULE__bindgen_ty_5>())).ns_ as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_RULE__bindgen_ty_5),
"::",
stringify!(ns_)
)
);
}
#[test]
fn bindgen_test_layout_YR_RULE() {
assert_eq!(
::std::mem::size_of::<YR_RULE>(),
48usize,
concat!("Size of: ", stringify!(YR_RULE))
);
assert_eq!(
::std::mem::align_of::<YR_RULE>(),
8usize,
concat!("Alignment of ", stringify!(YR_RULE))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULE>())).flags as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_RULE),
"::",
stringify!(flags)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULE>())).num_atoms as *const _ as usize },
4usize,
concat!(
"Offset of field: ",
stringify!(YR_RULE),
"::",
stringify!(num_atoms)
)
);
}
#[repr(C)]
#[derive(Copy, Clone)]
pub struct YR_EXTERNAL_VARIABLE {
pub type_: i32,
pub value: YR_EXTERNAL_VARIABLE__bindgen_ty_1,
pub __bindgen_anon_1: YR_EXTERNAL_VARIABLE__bindgen_ty_2,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union YR_EXTERNAL_VARIABLE__bindgen_ty_1 {
pub i: i64,
pub f: f64,
pub s: *mut ::std::os::raw::c_char,
}
#[test]
fn bindgen_test_layout_YR_EXTERNAL_VARIABLE__bindgen_ty_1() {
assert_eq!(
::std::mem::size_of::<YR_EXTERNAL_VARIABLE__bindgen_ty_1>(),
8usize,
concat!("Size of: ", stringify!(YR_EXTERNAL_VARIABLE__bindgen_ty_1))
);
assert_eq!(
::std::mem::align_of::<YR_EXTERNAL_VARIABLE__bindgen_ty_1>(),
8usize,
concat!(
"Alignment of ",
stringify!(YR_EXTERNAL_VARIABLE__bindgen_ty_1)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_EXTERNAL_VARIABLE__bindgen_ty_1>())).i as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_EXTERNAL_VARIABLE__bindgen_ty_1),
"::",
stringify!(i)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_EXTERNAL_VARIABLE__bindgen_ty_1>())).f as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_EXTERNAL_VARIABLE__bindgen_ty_1),
"::",
stringify!(f)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_EXTERNAL_VARIABLE__bindgen_ty_1>())).s as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_EXTERNAL_VARIABLE__bindgen_ty_1),
"::",
stringify!(s)
)
);
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union YR_EXTERNAL_VARIABLE__bindgen_ty_2 {
pub identifier: *const ::std::os::raw::c_char,
pub identifier_: YR_ARENA_REF,
}
#[test]
fn bindgen_test_layout_YR_EXTERNAL_VARIABLE__bindgen_ty_2() {
assert_eq!(
::std::mem::size_of::<YR_EXTERNAL_VARIABLE__bindgen_ty_2>(),
8usize,
concat!("Size of: ", stringify!(YR_EXTERNAL_VARIABLE__bindgen_ty_2))
);
assert_eq!(
::std::mem::align_of::<YR_EXTERNAL_VARIABLE__bindgen_ty_2>(),
8usize,
concat!(
"Alignment of ",
stringify!(YR_EXTERNAL_VARIABLE__bindgen_ty_2)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_EXTERNAL_VARIABLE__bindgen_ty_2>())).identifier as *const _
as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_EXTERNAL_VARIABLE__bindgen_ty_2),
"::",
stringify!(identifier)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_EXTERNAL_VARIABLE__bindgen_ty_2>())).identifier_ as *const _
as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_EXTERNAL_VARIABLE__bindgen_ty_2),
"::",
stringify!(identifier_)
)
);
}
#[test]
fn bindgen_test_layout_YR_EXTERNAL_VARIABLE() {
assert_eq!(
::std::mem::size_of::<YR_EXTERNAL_VARIABLE>(),
24usize,
concat!("Size of: ", stringify!(YR_EXTERNAL_VARIABLE))
);
assert_eq!(
::std::mem::align_of::<YR_EXTERNAL_VARIABLE>(),
8usize,
concat!("Alignment of ", stringify!(YR_EXTERNAL_VARIABLE))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_EXTERNAL_VARIABLE>())).type_ as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_EXTERNAL_VARIABLE),
"::",
stringify!(type_)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_EXTERNAL_VARIABLE>())).value as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(YR_EXTERNAL_VARIABLE),
"::",
stringify!(value)
)
);
}
#[repr(C)]
#[derive(Copy, Clone)]
pub struct YR_AC_MATCH {
pub __bindgen_anon_1: YR_AC_MATCH__bindgen_ty_1,
pub __bindgen_anon_2: YR_AC_MATCH__bindgen_ty_2,
pub __bindgen_anon_3: YR_AC_MATCH__bindgen_ty_3,
pub __bindgen_anon_4: YR_AC_MATCH__bindgen_ty_4,
pub backtrack: u16,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union YR_AC_MATCH__bindgen_ty_1 {
pub string: *mut YR_STRING,
pub string_: YR_ARENA_REF,
}
#[test]
fn bindgen_test_layout_YR_AC_MATCH__bindgen_ty_1() {
assert_eq!(
::std::mem::size_of::<YR_AC_MATCH__bindgen_ty_1>(),
8usize,
concat!("Size of: ", stringify!(YR_AC_MATCH__bindgen_ty_1))
);
assert_eq!(
::std::mem::align_of::<YR_AC_MATCH__bindgen_ty_1>(),
8usize,
concat!("Alignment of ", stringify!(YR_AC_MATCH__bindgen_ty_1))
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_AC_MATCH__bindgen_ty_1>())).string as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_AC_MATCH__bindgen_ty_1),
"::",
stringify!(string)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_AC_MATCH__bindgen_ty_1>())).string_ as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_AC_MATCH__bindgen_ty_1),
"::",
stringify!(string_)
)
);
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union YR_AC_MATCH__bindgen_ty_2 {
pub forward_code: *const u8,
pub forward_code_: YR_ARENA_REF,
}
#[test]
fn bindgen_test_layout_YR_AC_MATCH__bindgen_ty_2() {
assert_eq!(
::std::mem::size_of::<YR_AC_MATCH__bindgen_ty_2>(),
8usize,
concat!("Size of: ", stringify!(YR_AC_MATCH__bindgen_ty_2))
);
assert_eq!(
::std::mem::align_of::<YR_AC_MATCH__bindgen_ty_2>(),
8usize,
concat!("Alignment of ", stringify!(YR_AC_MATCH__bindgen_ty_2))
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_AC_MATCH__bindgen_ty_2>())).forward_code as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_AC_MATCH__bindgen_ty_2),
"::",
stringify!(forward_code)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_AC_MATCH__bindgen_ty_2>())).forward_code_ as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_AC_MATCH__bindgen_ty_2),
"::",
stringify!(forward_code_)
)
);
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union YR_AC_MATCH__bindgen_ty_3 {
pub backward_code: *const u8,
pub backward_code_: YR_ARENA_REF,
}
#[test]
fn bindgen_test_layout_YR_AC_MATCH__bindgen_ty_3() {
assert_eq!(
::std::mem::size_of::<YR_AC_MATCH__bindgen_ty_3>(),
8usize,
concat!("Size of: ", stringify!(YR_AC_MATCH__bindgen_ty_3))
);
assert_eq!(
::std::mem::align_of::<YR_AC_MATCH__bindgen_ty_3>(),
8usize,
concat!("Alignment of ", stringify!(YR_AC_MATCH__bindgen_ty_3))
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_AC_MATCH__bindgen_ty_3>())).backward_code as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_AC_MATCH__bindgen_ty_3),
"::",
stringify!(backward_code)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_AC_MATCH__bindgen_ty_3>())).backward_code_ as *const _
as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_AC_MATCH__bindgen_ty_3),
"::",
stringify!(backward_code_)
)
);
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union YR_AC_MATCH__bindgen_ty_4 {
pub next: *mut YR_AC_MATCH,
pub next_: YR_ARENA_REF,
}
#[test]
fn bindgen_test_layout_YR_AC_MATCH__bindgen_ty_4() {
assert_eq!(
::std::mem::size_of::<YR_AC_MATCH__bindgen_ty_4>(),
8usize,
concat!("Size of: ", stringify!(YR_AC_MATCH__bindgen_ty_4))
);
assert_eq!(
::std::mem::align_of::<YR_AC_MATCH__bindgen_ty_4>(),
8usize,
concat!("Alignment of ", stringify!(YR_AC_MATCH__bindgen_ty_4))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_AC_MATCH__bindgen_ty_4>())).next as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_AC_MATCH__bindgen_ty_4),
"::",
stringify!(next)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_AC_MATCH__bindgen_ty_4>())).next_ as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_AC_MATCH__bindgen_ty_4),
"::",
stringify!(next_)
)
);
}
#[test]
fn bindgen_test_layout_YR_AC_MATCH() {
assert_eq!(
::std::mem::size_of::<YR_AC_MATCH>(),
40usize,
concat!("Size of: ", stringify!(YR_AC_MATCH))
);
assert_eq!(
::std::mem::align_of::<YR_AC_MATCH>(),
8usize,
concat!("Alignment of ", stringify!(YR_AC_MATCH))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_AC_MATCH>())).backtrack as *const _ as usize },
32usize,
concat!(
"Offset of field: ",
stringify!(YR_AC_MATCH),
"::",
stringify!(backtrack)
)
);
}
#[repr(C)]
#[derive(Copy, Clone)]
pub struct RE_NODE {
pub type_: ::std::os::raw::c_int,
pub __bindgen_anon_1: RE_NODE__bindgen_ty_1,
pub __bindgen_anon_2: RE_NODE__bindgen_ty_2,
pub greedy: ::std::os::raw::c_int,
pub re_class: *mut RE_CLASS,
pub children_head: *mut RE_NODE,
pub children_tail: *mut RE_NODE,
pub prev_sibling: *mut RE_NODE,
pub next_sibling: *mut RE_NODE,
pub forward_code_ref: YR_ARENA_REF,
pub backward_code_ref: YR_ARENA_REF,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union RE_NODE__bindgen_ty_1 {
pub value: ::std::os::raw::c_int,
pub count: ::std::os::raw::c_int,
pub start: ::std::os::raw::c_int,
}
#[test]
fn bindgen_test_layout_RE_NODE__bindgen_ty_1() {
assert_eq!(
::std::mem::size_of::<RE_NODE__bindgen_ty_1>(),
4usize,
concat!("Size of: ", stringify!(RE_NODE__bindgen_ty_1))
);
assert_eq!(
::std::mem::align_of::<RE_NODE__bindgen_ty_1>(),
4usize,
concat!("Alignment of ", stringify!(RE_NODE__bindgen_ty_1))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_NODE__bindgen_ty_1>())).value as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(RE_NODE__bindgen_ty_1),
"::",
stringify!(value)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_NODE__bindgen_ty_1>())).count as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(RE_NODE__bindgen_ty_1),
"::",
stringify!(count)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_NODE__bindgen_ty_1>())).start as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(RE_NODE__bindgen_ty_1),
"::",
stringify!(start)
)
);
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union RE_NODE__bindgen_ty_2 {
pub mask: ::std::os::raw::c_int,
pub end: ::std::os::raw::c_int,
}
#[test]
fn bindgen_test_layout_RE_NODE__bindgen_ty_2() {
assert_eq!(
::std::mem::size_of::<RE_NODE__bindgen_ty_2>(),
4usize,
concat!("Size of: ", stringify!(RE_NODE__bindgen_ty_2))
);
assert_eq!(
::std::mem::align_of::<RE_NODE__bindgen_ty_2>(),
4usize,
concat!("Alignment of ", stringify!(RE_NODE__bindgen_ty_2))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_NODE__bindgen_ty_2>())).mask as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(RE_NODE__bindgen_ty_2),
"::",
stringify!(mask)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_NODE__bindgen_ty_2>())).end as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(RE_NODE__bindgen_ty_2),
"::",
stringify!(end)
)
);
}
#[test]
fn bindgen_test_layout_RE_NODE() {
assert_eq!(
::std::mem::size_of::<RE_NODE>(),
72usize,
concat!("Size of: ", stringify!(RE_NODE))
);
assert_eq!(
::std::mem::align_of::<RE_NODE>(),
8usize,
concat!("Alignment of ", stringify!(RE_NODE))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_NODE>())).type_ as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(RE_NODE),
"::",
stringify!(type_)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_NODE>())).greedy as *const _ as usize },
12usize,
concat!(
"Offset of field: ",
stringify!(RE_NODE),
"::",
stringify!(greedy)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_NODE>())).re_class as *const _ as usize },
16usize,
concat!(
"Offset of field: ",
stringify!(RE_NODE),
"::",
stringify!(re_class)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_NODE>())).children_head as *const _ as usize },
24usize,
concat!(
"Offset of field: ",
stringify!(RE_NODE),
"::",
stringify!(children_head)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_NODE>())).children_tail as *const _ as usize },
32usize,
concat!(
"Offset of field: ",
stringify!(RE_NODE),
"::",
stringify!(children_tail)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_NODE>())).prev_sibling as *const _ as usize },
40usize,
concat!(
"Offset of field: ",
stringify!(RE_NODE),
"::",
stringify!(prev_sibling)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_NODE>())).next_sibling as *const _ as usize },
48usize,
concat!(
"Offset of field: ",
stringify!(RE_NODE),
"::",
stringify!(next_sibling)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_NODE>())).forward_code_ref as *const _ as usize },
56usize,
concat!(
"Offset of field: ",
stringify!(RE_NODE),
"::",
stringify!(forward_code_ref)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_NODE>())).backward_code_ref as *const _ as usize },
64usize,
concat!(
"Offset of field: ",
stringify!(RE_NODE),
"::",
stringify!(backward_code_ref)
)
);
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct RE_CLASS {
pub negated: u8,
pub bitmap: [u8; 32usize],
}
#[test]
fn bindgen_test_layout_RE_CLASS() {
assert_eq!(
::std::mem::size_of::<RE_CLASS>(),
33usize,
concat!("Size of: ", stringify!(RE_CLASS))
);
assert_eq!(
::std::mem::align_of::<RE_CLASS>(),
1usize,
concat!("Alignment of ", stringify!(RE_CLASS))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_CLASS>())).negated as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(RE_CLASS),
"::",
stringify!(negated)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_CLASS>())).bitmap as *const _ as usize },
1usize,
concat!(
"Offset of field: ",
stringify!(RE_CLASS),
"::",
stringify!(bitmap)
)
);
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct RE_AST {
pub flags: u32,
pub root_node: *mut RE_NODE,
}
#[test]
fn bindgen_test_layout_RE_AST() {
assert_eq!(
::std::mem::size_of::<RE_AST>(),
16usize,
concat!("Size of: ", stringify!(RE_AST))
);
assert_eq!(
::std::mem::align_of::<RE_AST>(),
8usize,
concat!("Alignment of ", stringify!(RE_AST))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_AST>())).flags as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(RE_AST),
"::",
stringify!(flags)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_AST>())).root_node as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(RE_AST),
"::",
stringify!(root_node)
)
);
}
#[repr(C)]
#[derive(Copy, Clone)]
pub struct RE_FIBER {
pub ip: *const u8,
pub sp: i32,
pub rc: i32,
pub prev: *mut RE_FIBER,
pub next: *mut RE_FIBER,
pub stack: [u16; 1024usize],
}
#[test]
fn bindgen_test_layout_RE_FIBER() {
assert_eq!(
::std::mem::size_of::<RE_FIBER>(),
2080usize,
concat!("Size of: ", stringify!(RE_FIBER))
);
assert_eq!(
::std::mem::align_of::<RE_FIBER>(),
8usize,
concat!("Alignment of ", stringify!(RE_FIBER))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_FIBER>())).ip as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(RE_FIBER),
"::",
stringify!(ip)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_FIBER>())).sp as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(RE_FIBER),
"::",
stringify!(sp)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_FIBER>())).rc as *const _ as usize },
12usize,
concat!(
"Offset of field: ",
stringify!(RE_FIBER),
"::",
stringify!(rc)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_FIBER>())).prev as *const _ as usize },
16usize,
concat!(
"Offset of field: ",
stringify!(RE_FIBER),
"::",
stringify!(prev)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_FIBER>())).next as *const _ as usize },
24usize,
concat!(
"Offset of field: ",
stringify!(RE_FIBER),
"::",
stringify!(next)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_FIBER>())).stack as *const _ as usize },
32usize,
concat!(
"Offset of field: ",
stringify!(RE_FIBER),
"::",
stringify!(stack)
)
);
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct RE_FIBER_LIST {
pub head: *mut RE_FIBER,
pub tail: *mut RE_FIBER,
}
#[test]
fn bindgen_test_layout_RE_FIBER_LIST() {
assert_eq!(
::std::mem::size_of::<RE_FIBER_LIST>(),
16usize,
concat!("Size of: ", stringify!(RE_FIBER_LIST))
);
assert_eq!(
::std::mem::align_of::<RE_FIBER_LIST>(),
8usize,
concat!("Alignment of ", stringify!(RE_FIBER_LIST))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_FIBER_LIST>())).head as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(RE_FIBER_LIST),
"::",
stringify!(head)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_FIBER_LIST>())).tail as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(RE_FIBER_LIST),
"::",
stringify!(tail)
)
);
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct RE_FIBER_POOL {
pub fiber_count: ::std::os::raw::c_int,
pub fibers: RE_FIBER_LIST,
}
#[test]
fn bindgen_test_layout_RE_FIBER_POOL() {
assert_eq!(
::std::mem::size_of::<RE_FIBER_POOL>(),
24usize,
concat!("Size of: ", stringify!(RE_FIBER_POOL))
);
assert_eq!(
::std::mem::align_of::<RE_FIBER_POOL>(),
8usize,
concat!("Alignment of ", stringify!(RE_FIBER_POOL))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_FIBER_POOL>())).fiber_count as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(RE_FIBER_POOL),
"::",
stringify!(fiber_count)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<RE_FIBER_POOL>())).fibers as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(RE_FIBER_POOL),
"::",
stringify!(fibers)
)
);
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct YR_MATCHES {
pub head: *mut YR_MATCH,
pub tail: *mut YR_MATCH,
pub count: i32,
}
#[test]
fn bindgen_test_layout_YR_MATCHES() {
assert_eq!(
::std::mem::size_of::<YR_MATCHES>(),
24usize,
concat!("Size of: ", stringify!(YR_MATCHES))
);
assert_eq!(
::std::mem::align_of::<YR_MATCHES>(),
8usize,
concat!("Alignment of ", stringify!(YR_MATCHES))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_MATCHES>())).head as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_MATCHES),
"::",
stringify!(head)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_MATCHES>())).tail as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(YR_MATCHES),
"::",
stringify!(tail)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_MATCHES>())).count as *const _ as usize },
16usize,
concat!(
"Offset of field: ",
stringify!(YR_MATCHES),
"::",
stringify!(count)
)
);
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct YR_MATCH {
pub base: i64,
pub offset: i64,
pub match_length: i32,
pub data_length: i32,
pub data: *const u8,
pub prev: *mut YR_MATCH,
pub next: *mut YR_MATCH,
pub chain_length: i32,
pub is_private: bool,
}
#[test]
fn bindgen_test_layout_YR_MATCH() {
assert_eq!(
::std::mem::size_of::<YR_MATCH>(),
56usize,
concat!("Size of: ", stringify!(YR_MATCH))
);
assert_eq!(
::std::mem::align_of::<YR_MATCH>(),
8usize,
concat!("Alignment of ", stringify!(YR_MATCH))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_MATCH>())).base as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_MATCH),
"::",
stringify!(base)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_MATCH>())).offset as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(YR_MATCH),
"::",
stringify!(offset)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_MATCH>())).match_length as *const _ as usize },
16usize,
concat!(
"Offset of field: ",
stringify!(YR_MATCH),
"::",
stringify!(match_length)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_MATCH>())).data_length as *const _ as usize },
20usize,
concat!(
"Offset of field: ",
stringify!(YR_MATCH),
"::",
stringify!(data_length)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_MATCH>())).data as *const _ as usize },
24usize,
concat!(
"Offset of field: ",
stringify!(YR_MATCH),
"::",
stringify!(data)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_MATCH>())).prev as *const _ as usize },
32usize,
concat!(
"Offset of field: ",
stringify!(YR_MATCH),
"::",
stringify!(prev)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_MATCH>())).next as *const _ as usize },
40usize,
concat!(
"Offset of field: ",
stringify!(YR_MATCH),
"::",
stringify!(next)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_MATCH>())).chain_length as *const _ as usize },
48usize,
concat!(
"Offset of field: ",
stringify!(YR_MATCH),
"::",
stringify!(chain_length)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_MATCH>())).is_private as *const _ as usize },
52usize,
concat!(
"Offset of field: ",
stringify!(YR_MATCH),
"::",
stringify!(is_private)
)
);
}
#[repr(C)]
#[derive(Copy, Clone)]
pub struct YR_RULES {
pub arena: *mut YR_ARENA,
pub __bindgen_anon_1: YR_RULES__bindgen_ty_1,
pub __bindgen_anon_2: YR_RULES__bindgen_ty_2,
pub __bindgen_anon_3: YR_RULES__bindgen_ty_3,
pub ac_transition_table: *mut YR_AC_TRANSITION,
pub ac_match_pool: *mut YR_AC_MATCH,
pub ac_match_table: *mut u32,
pub code_start: *const u8,
pub num_rules: u32,
pub num_strings: u32,
pub num_namespaces: u32,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union YR_RULES__bindgen_ty_1 {
pub rules_table: *mut YR_RULE,
pub rules_list_head: *mut YR_RULE,
}
#[test]
fn bindgen_test_layout_YR_RULES__bindgen_ty_1() {
assert_eq!(
::std::mem::size_of::<YR_RULES__bindgen_ty_1>(),
8usize,
concat!("Size of: ", stringify!(YR_RULES__bindgen_ty_1))
);
assert_eq!(
::std::mem::align_of::<YR_RULES__bindgen_ty_1>(),
8usize,
concat!("Alignment of ", stringify!(YR_RULES__bindgen_ty_1))
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_RULES__bindgen_ty_1>())).rules_table as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_RULES__bindgen_ty_1),
"::",
stringify!(rules_table)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_RULES__bindgen_ty_1>())).rules_list_head as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_RULES__bindgen_ty_1),
"::",
stringify!(rules_list_head)
)
);
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union YR_RULES__bindgen_ty_2 {
pub strings_table: *mut YR_STRING,
pub strings_list_head: *mut YR_STRING,
}
#[test]
fn bindgen_test_layout_YR_RULES__bindgen_ty_2() {
assert_eq!(
::std::mem::size_of::<YR_RULES__bindgen_ty_2>(),
8usize,
concat!("Size of: ", stringify!(YR_RULES__bindgen_ty_2))
);
assert_eq!(
::std::mem::align_of::<YR_RULES__bindgen_ty_2>(),
8usize,
concat!("Alignment of ", stringify!(YR_RULES__bindgen_ty_2))
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_RULES__bindgen_ty_2>())).strings_table as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_RULES__bindgen_ty_2),
"::",
stringify!(strings_table)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_RULES__bindgen_ty_2>())).strings_list_head as *const _
as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_RULES__bindgen_ty_2),
"::",
stringify!(strings_list_head)
)
);
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union YR_RULES__bindgen_ty_3 {
pub ext_vars_table: *mut YR_EXTERNAL_VARIABLE,
pub externals_list_head: *mut YR_EXTERNAL_VARIABLE,
}
#[test]
fn bindgen_test_layout_YR_RULES__bindgen_ty_3() {
assert_eq!(
::std::mem::size_of::<YR_RULES__bindgen_ty_3>(),
8usize,
concat!("Size of: ", stringify!(YR_RULES__bindgen_ty_3))
);
assert_eq!(
::std::mem::align_of::<YR_RULES__bindgen_ty_3>(),
8usize,
concat!("Alignment of ", stringify!(YR_RULES__bindgen_ty_3))
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_RULES__bindgen_ty_3>())).ext_vars_table as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_RULES__bindgen_ty_3),
"::",
stringify!(ext_vars_table)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_RULES__bindgen_ty_3>())).externals_list_head as *const _
as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_RULES__bindgen_ty_3),
"::",
stringify!(externals_list_head)
)
);
}
#[test]
fn bindgen_test_layout_YR_RULES() {
assert_eq!(
::std::mem::size_of::<YR_RULES>(),
80usize,
concat!("Size of: ", stringify!(YR_RULES))
);
assert_eq!(
::std::mem::align_of::<YR_RULES>(),
8usize,
concat!("Alignment of ", stringify!(YR_RULES))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULES>())).arena as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_RULES),
"::",
stringify!(arena)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULES>())).ac_transition_table as *const _ as usize },
32usize,
concat!(
"Offset of field: ",
stringify!(YR_RULES),
"::",
stringify!(ac_transition_table)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULES>())).ac_match_pool as *const _ as usize },
40usize,
concat!(
"Offset of field: ",
stringify!(YR_RULES),
"::",
stringify!(ac_match_pool)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULES>())).ac_match_table as *const _ as usize },
48usize,
concat!(
"Offset of field: ",
stringify!(YR_RULES),
"::",
stringify!(ac_match_table)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULES>())).code_start as *const _ as usize },
56usize,
concat!(
"Offset of field: ",
stringify!(YR_RULES),
"::",
stringify!(code_start)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULES>())).num_rules as *const _ as usize },
64usize,
concat!(
"Offset of field: ",
stringify!(YR_RULES),
"::",
stringify!(num_rules)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULES>())).num_strings as *const _ as usize },
68usize,
concat!(
"Offset of field: ",
stringify!(YR_RULES),
"::",
stringify!(num_strings)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULES>())).num_namespaces as *const _ as usize },
72usize,
concat!(
"Offset of field: ",
stringify!(YR_RULES),
"::",
stringify!(num_namespaces)
)
);
}
#[repr(C)]
#[derive(Copy, Clone)]
pub struct YR_RULES_STATS {
pub num_rules: u32,
pub num_strings: u32,
pub ac_matches: u32,
pub ac_root_match_list_length: u32,
pub ac_average_match_list_length: f32,
pub top_ac_match_list_lengths: [u32; 100usize],
pub ac_match_list_length_pctls: [u32; 101usize],
pub ac_tables_size: u32,
}
#[test]
fn bindgen_test_layout_YR_RULES_STATS() {
assert_eq!(
::std::mem::size_of::<YR_RULES_STATS>(),
828usize,
concat!("Size of: ", stringify!(YR_RULES_STATS))
);
assert_eq!(
::std::mem::align_of::<YR_RULES_STATS>(),
4usize,
concat!("Alignment of ", stringify!(YR_RULES_STATS))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULES_STATS>())).num_rules as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_RULES_STATS),
"::",
stringify!(num_rules)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULES_STATS>())).num_strings as *const _ as usize },
4usize,
concat!(
"Offset of field: ",
stringify!(YR_RULES_STATS),
"::",
stringify!(num_strings)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULES_STATS>())).ac_matches as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(YR_RULES_STATS),
"::",
stringify!(ac_matches)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_RULES_STATS>())).ac_root_match_list_length as *const _
as usize
},
12usize,
concat!(
"Offset of field: ",
stringify!(YR_RULES_STATS),
"::",
stringify!(ac_root_match_list_length)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_RULES_STATS>())).ac_average_match_list_length as *const _
as usize
},
16usize,
concat!(
"Offset of field: ",
stringify!(YR_RULES_STATS),
"::",
stringify!(ac_average_match_list_length)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_RULES_STATS>())).top_ac_match_list_lengths as *const _
as usize
},
20usize,
concat!(
"Offset of field: ",
stringify!(YR_RULES_STATS),
"::",
stringify!(top_ac_match_list_lengths)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_RULES_STATS>())).ac_match_list_length_pctls as *const _
as usize
},
420usize,
concat!(
"Offset of field: ",
stringify!(YR_RULES_STATS),
"::",
stringify!(ac_match_list_length_pctls)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULES_STATS>())).ac_tables_size as *const _ as usize },
824usize,
concat!(
"Offset of field: ",
stringify!(YR_RULES_STATS),
"::",
stringify!(ac_tables_size)
)
);
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct YR_PROFILING_INFO {
pub atom_matches: u32,
pub match_time: u64,
pub exec_time: u64,
}
#[test]
fn bindgen_test_layout_YR_PROFILING_INFO() {
assert_eq!(
::std::mem::size_of::<YR_PROFILING_INFO>(),
24usize,
concat!("Size of: ", stringify!(YR_PROFILING_INFO))
);
assert_eq!(
::std::mem::align_of::<YR_PROFILING_INFO>(),
8usize,
concat!("Alignment of ", stringify!(YR_PROFILING_INFO))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_PROFILING_INFO>())).atom_matches as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_PROFILING_INFO),
"::",
stringify!(atom_matches)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_PROFILING_INFO>())).match_time as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(YR_PROFILING_INFO),
"::",
stringify!(match_time)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_PROFILING_INFO>())).exec_time as *const _ as usize },
16usize,
concat!(
"Offset of field: ",
stringify!(YR_PROFILING_INFO),
"::",
stringify!(exec_time)
)
);
}
#[doc = ""]
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct YR_RULE_PROFILING_INFO {
pub rule: *mut YR_RULE,
pub cost: u64,
}
#[test]
fn bindgen_test_layout_YR_RULE_PROFILING_INFO() {
assert_eq!(
::std::mem::size_of::<YR_RULE_PROFILING_INFO>(),
16usize,
concat!("Size of: ", stringify!(YR_RULE_PROFILING_INFO))
);
assert_eq!(
::std::mem::align_of::<YR_RULE_PROFILING_INFO>(),
8usize,
concat!("Alignment of ", stringify!(YR_RULE_PROFILING_INFO))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULE_PROFILING_INFO>())).rule as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_RULE_PROFILING_INFO),
"::",
stringify!(rule)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_RULE_PROFILING_INFO>())).cost as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(YR_RULE_PROFILING_INFO),
"::",
stringify!(cost)
)
);
}
pub type YR_MEMORY_BLOCK_FETCH_DATA_FUNC =
::std::option::Option<unsafe extern "C" fn(self_: *mut YR_MEMORY_BLOCK) -> *const u8>;
pub type YR_MEMORY_BLOCK_ITERATOR_FUNC = ::std::option::Option<
unsafe extern "C" fn(self_: *mut YR_MEMORY_BLOCK_ITERATOR) -> *mut YR_MEMORY_BLOCK,
>;
pub type YR_MEMORY_BLOCK_ITERATOR_SIZE_FUNC =
::std::option::Option<unsafe extern "C" fn(self_: *mut YR_MEMORY_BLOCK_ITERATOR) -> u64>;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct YR_MEMORY_BLOCK {
pub size: size_t,
pub base: u64,
pub context: *mut ::std::os::raw::c_void,
pub fetch_data: YR_MEMORY_BLOCK_FETCH_DATA_FUNC,
}
#[test]
fn bindgen_test_layout_YR_MEMORY_BLOCK() {
assert_eq!(
::std::mem::size_of::<YR_MEMORY_BLOCK>(),
32usize,
concat!("Size of: ", stringify!(YR_MEMORY_BLOCK))
);
assert_eq!(
::std::mem::align_of::<YR_MEMORY_BLOCK>(),
8usize,
concat!("Alignment of ", stringify!(YR_MEMORY_BLOCK))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_MEMORY_BLOCK>())).size as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_MEMORY_BLOCK),
"::",
stringify!(size)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_MEMORY_BLOCK>())).base as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(YR_MEMORY_BLOCK),
"::",
stringify!(base)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_MEMORY_BLOCK>())).context as *const _ as usize },
16usize,
concat!(
"Offset of field: ",
stringify!(YR_MEMORY_BLOCK),
"::",
stringify!(context)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_MEMORY_BLOCK>())).fetch_data as *const _ as usize },
24usize,
concat!(
"Offset of field: ",
stringify!(YR_MEMORY_BLOCK),
"::",
stringify!(fetch_data)
)
);
}
#[doc = ""]
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct YR_MEMORY_BLOCK_ITERATOR {
pub context: *mut ::std::os::raw::c_void,
pub first: YR_MEMORY_BLOCK_ITERATOR_FUNC,
pub next: YR_MEMORY_BLOCK_ITERATOR_FUNC,
pub file_size: YR_MEMORY_BLOCK_ITERATOR_SIZE_FUNC,
pub last_error: ::std::os::raw::c_int,
}
#[test]
fn bindgen_test_layout_YR_MEMORY_BLOCK_ITERATOR() {
assert_eq!(
::std::mem::size_of::<YR_MEMORY_BLOCK_ITERATOR>(),
40usize,
concat!("Size of: ", stringify!(YR_MEMORY_BLOCK_ITERATOR))
);
assert_eq!(
::std::mem::align_of::<YR_MEMORY_BLOCK_ITERATOR>(),
8usize,
concat!("Alignment of ", stringify!(YR_MEMORY_BLOCK_ITERATOR))
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_MEMORY_BLOCK_ITERATOR>())).context as *const _ as usize
},
0usize,
concat!(
"Offset of field: ",
stringify!(YR_MEMORY_BLOCK_ITERATOR),
"::",
stringify!(context)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_MEMORY_BLOCK_ITERATOR>())).first as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(YR_MEMORY_BLOCK_ITERATOR),
"::",
stringify!(first)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_MEMORY_BLOCK_ITERATOR>())).next as *const _ as usize },
16usize,
concat!(
"Offset of field: ",
stringify!(YR_MEMORY_BLOCK_ITERATOR),
"::",
stringify!(next)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_MEMORY_BLOCK_ITERATOR>())).file_size as *const _ as usize
},
24usize,
concat!(
"Offset of field: ",
stringify!(YR_MEMORY_BLOCK_ITERATOR),
"::",
stringify!(file_size)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_MEMORY_BLOCK_ITERATOR>())).last_error as *const _ as usize
},
32usize,
concat!(
"Offset of field: ",
stringify!(YR_MEMORY_BLOCK_ITERATOR),
"::",
stringify!(last_error)
)
);
}
pub type YR_CALLBACK_FUNC = ::std::option::Option<
unsafe extern "C" fn(
context: *mut YR_SCAN_CONTEXT,
message: ::std::os::raw::c_int,
message_data: *mut ::std::os::raw::c_void,
user_data: *mut ::std::os::raw::c_void,
) -> ::std::os::raw::c_int,
>;
#[repr(C)]
#[derive(Copy, Clone)]
pub struct YR_SCAN_CONTEXT {
pub file_size: u64,
pub entry_point: u64,
pub flags: ::std::os::raw::c_int,
pub canary: ::std::os::raw::c_int,
pub timeout: u64,
pub user_data: *mut ::std::os::raw::c_void,
pub callback: YR_CALLBACK_FUNC,
pub rules: *mut YR_RULES,
pub last_error_string: *mut YR_STRING,
pub iterator: *mut YR_MEMORY_BLOCK_ITERATOR,
pub objects_table: *mut YR_HASH_TABLE,
pub matches_notebook: *mut YR_NOTEBOOK,
pub stopwatch: YR_STOPWATCH,
pub re_fiber_pool: RE_FIBER_POOL,
pub rule_matches_flags: *mut ::std::os::raw::c_ulong,
pub ns_unsatisfied_flags: *mut ::std::os::raw::c_ulong,
pub matches: *mut YR_MATCHES,
pub unconfirmed_matches: *mut YR_MATCHES,
pub profiling_info: *mut YR_PROFILING_INFO,
}
#[test]
fn bindgen_test_layout_YR_SCAN_CONTEXT() {
assert_eq!(
::std::mem::size_of::<YR_SCAN_CONTEXT>(),
168usize,
concat!("Size of: ", stringify!(YR_SCAN_CONTEXT))
);
assert_eq!(
::std::mem::align_of::<YR_SCAN_CONTEXT>(),
8usize,
concat!("Alignment of ", stringify!(YR_SCAN_CONTEXT))
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_SCAN_CONTEXT>())).file_size as *const _ as usize },
0usize,
concat!(
"Offset of field: ",
stringify!(YR_SCAN_CONTEXT),
"::",
stringify!(file_size)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_SCAN_CONTEXT>())).entry_point as *const _ as usize },
8usize,
concat!(
"Offset of field: ",
stringify!(YR_SCAN_CONTEXT),
"::",
stringify!(entry_point)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_SCAN_CONTEXT>())).flags as *const _ as usize },
16usize,
concat!(
"Offset of field: ",
stringify!(YR_SCAN_CONTEXT),
"::",
stringify!(flags)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_SCAN_CONTEXT>())).canary as *const _ as usize },
20usize,
concat!(
"Offset of field: ",
stringify!(YR_SCAN_CONTEXT),
"::",
stringify!(canary)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_SCAN_CONTEXT>())).timeout as *const _ as usize },
24usize,
concat!(
"Offset of field: ",
stringify!(YR_SCAN_CONTEXT),
"::",
stringify!(timeout)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_SCAN_CONTEXT>())).user_data as *const _ as usize },
32usize,
concat!(
"Offset of field: ",
stringify!(YR_SCAN_CONTEXT),
"::",
stringify!(user_data)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_SCAN_CONTEXT>())).callback as *const _ as usize },
40usize,
concat!(
"Offset of field: ",
stringify!(YR_SCAN_CONTEXT),
"::",
stringify!(callback)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_SCAN_CONTEXT>())).rules as *const _ as usize },
48usize,
concat!(
"Offset of field: ",
stringify!(YR_SCAN_CONTEXT),
"::",
stringify!(rules)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_SCAN_CONTEXT>())).last_error_string as *const _ as usize
},
56usize,
concat!(
"Offset of field: ",
stringify!(YR_SCAN_CONTEXT),
"::",
stringify!(last_error_string)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_SCAN_CONTEXT>())).iterator as *const _ as usize },
64usize,
concat!(
"Offset of field: ",
stringify!(YR_SCAN_CONTEXT),
"::",
stringify!(iterator)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_SCAN_CONTEXT>())).objects_table as *const _ as usize },
72usize,
concat!(
"Offset of field: ",
stringify!(YR_SCAN_CONTEXT),
"::",
stringify!(objects_table)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_SCAN_CONTEXT>())).matches_notebook as *const _ as usize
},
80usize,
concat!(
"Offset of field: ",
stringify!(YR_SCAN_CONTEXT),
"::",
stringify!(matches_notebook)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_SCAN_CONTEXT>())).stopwatch as *const _ as usize },
88usize,
concat!(
"Offset of field: ",
stringify!(YR_SCAN_CONTEXT),
"::",
stringify!(stopwatch)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_SCAN_CONTEXT>())).re_fiber_pool as *const _ as usize },
104usize,
concat!(
"Offset of field: ",
stringify!(YR_SCAN_CONTEXT),
"::",
stringify!(re_fiber_pool)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_SCAN_CONTEXT>())).rule_matches_flags as *const _ as usize
},
128usize,
concat!(
"Offset of field: ",
stringify!(YR_SCAN_CONTEXT),
"::",
stringify!(rule_matches_flags)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_SCAN_CONTEXT>())).ns_unsatisfied_flags as *const _ as usize
},
136usize,
concat!(
"Offset of field: ",
stringify!(YR_SCAN_CONTEXT),
"::",
stringify!(ns_unsatisfied_flags)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_SCAN_CONTEXT>())).matches as *const _ as usize },
144usize,
concat!(
"Offset of field: ",
stringify!(YR_SCAN_CONTEXT),
"::",
stringify!(matches)
)
);
assert_eq!(
unsafe {
&(*(::std::ptr::null::<YR_SCAN_CONTEXT>())).unconfirmed_matches as *const _ as usize
},
152usize,
concat!(
"Offset of field: ",
stringify!(YR_SCAN_CONTEXT),
"::",
stringify!(unconfirmed_matches)
)
);
assert_eq!(
unsafe { &(*(::std::ptr::null::<YR_SCAN_CONTEXT>())).profiling_info as *const _ as usize },
160usize,
concat!(
"Offset of field: ",
stringify!(YR_SCAN_CONTEXT),
"::",
stringify!(profiling_info)
)
);
}
pub type YR_COMPILER_CALLBACK_FUNC = ::std::option::Option<
unsafe extern "C" fn(
error_level: ::std::os::raw::c_int,
file_name: *const ::std::os::raw::c_char,
line_number: ::std::os::raw::c_int,
rule: *const YR_RULE,
message: *const ::std::os::raw::c_char,
user_data: *mut ::std::os::raw::c_void,
),
>;
pub type YR_COMPILER_INCLUDE_CALLBACK_FUNC = ::std::option::Option<
unsafe extern "C" fn(
include_name: *const ::std::os::raw::c_char,
calling_rule_filename: *const ::std::os::raw::c_char,
calling_rule_namespace: *const ::std::os::raw::c_char,
user_data: *mut ::std::os::raw::c_void,
) -> *const ::std::os::raw::c_char,
>;
pub type YR_COMPILER_INCLUDE_FREE_FUNC = ::std::option::Option<
unsafe extern "C" fn(
callback_result_ptr: *const ::std::os::raw::c_char,
user_data: *mut ::std::os::raw::c_void,
),
>;
pub type YR_COMPILER_RE_AST_CALLBACK_FUNC = ::std::option::Option<
unsafe extern "C" fn(
rule: *const YR_RULE,
string_identifier: *const ::std::os::raw::c_char,
re_ast: *const RE_AST,
user_data: *mut ::std::os::raw::c_void,
),
>;
pub type YR_COMPILER = [u64; 1298usize];
extern "C" {
pub fn yr_compiler_create(compiler: *mut *mut YR_COMPILER) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_compiler_destroy(compiler: *mut YR_COMPILER);
}
extern "C" {
pub fn yr_compiler_set_callback(
compiler: *mut YR_COMPILER,
callback: YR_COMPILER_CALLBACK_FUNC,
user_data: *mut ::std::os::raw::c_void,
);
}
extern "C" {
pub fn yr_compiler_set_include_callback(
compiler: *mut YR_COMPILER,
include_callback: YR_COMPILER_INCLUDE_CALLBACK_FUNC,
include_free: YR_COMPILER_INCLUDE_FREE_FUNC,
user_data: *mut ::std::os::raw::c_void,
);
}
extern "C" {
pub fn yr_compiler_set_re_ast_callback(
compiler: *mut YR_COMPILER,
re_ast_callback: YR_COMPILER_RE_AST_CALLBACK_FUNC,
user_data: *mut ::std::os::raw::c_void,
);
}
extern "C" {
pub fn yr_compiler_set_atom_quality_table(
compiler: *mut YR_COMPILER,
table: *const ::std::os::raw::c_void,
entries: ::std::os::raw::c_int,
warning_threshold: ::std::os::raw::c_uchar,
);
}
extern "C" {
pub fn yr_compiler_load_atom_quality_table(
compiler: *mut YR_COMPILER,
filename: *const ::std::os::raw::c_char,
warning_threshold: ::std::os::raw::c_uchar,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_compiler_add_file(
compiler: *mut YR_COMPILER,
rules_file: *mut FILE,
namespace_: *const ::std::os::raw::c_char,
file_name: *const ::std::os::raw::c_char,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_compiler_add_fd(
compiler: *mut YR_COMPILER,
rules_fd: ::std::os::raw::c_int,
namespace_: *const ::std::os::raw::c_char,
file_name: *const ::std::os::raw::c_char,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_compiler_add_string(
compiler: *mut YR_COMPILER,
rules_string: *const ::std::os::raw::c_char,
namespace_: *const ::std::os::raw::c_char,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_compiler_get_error_message(
compiler: *mut YR_COMPILER,
buffer: *mut ::std::os::raw::c_char,
buffer_size: ::std::os::raw::c_int,
) -> *mut ::std::os::raw::c_char;
}
extern "C" {
pub fn yr_compiler_get_current_file_name(
compiler: *mut YR_COMPILER,
) -> *mut ::std::os::raw::c_char;
}
extern "C" {
pub fn yr_compiler_define_integer_variable(
compiler: *mut YR_COMPILER,
identifier: *const ::std::os::raw::c_char,
value: i64,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_compiler_define_boolean_variable(
compiler: *mut YR_COMPILER,
identifier: *const ::std::os::raw::c_char,
value: ::std::os::raw::c_int,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_compiler_define_float_variable(
compiler: *mut YR_COMPILER,
identifier: *const ::std::os::raw::c_char,
value: f64,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_compiler_define_string_variable(
compiler: *mut YR_COMPILER,
identifier: *const ::std::os::raw::c_char,
value: *const ::std::os::raw::c_char,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_compiler_get_rules(
compiler: *mut YR_COMPILER,
rules: *mut *mut YR_RULES,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_initialize() -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_finalize() -> ::std::os::raw::c_int;
}
pub type YR_SCANNER = YR_SCAN_CONTEXT;
extern "C" {
pub fn yr_scanner_create(
rules: *mut YR_RULES,
scanner: *mut *mut YR_SCANNER,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_scanner_destroy(scanner: *mut YR_SCANNER);
}
extern "C" {
pub fn yr_scanner_set_callback(
scanner: *mut YR_SCANNER,
callback: YR_CALLBACK_FUNC,
user_data: *mut ::std::os::raw::c_void,
);
}
extern "C" {
pub fn yr_scanner_set_timeout(scanner: *mut YR_SCANNER, timeout: ::std::os::raw::c_int);
}
extern "C" {
pub fn yr_scanner_set_flags(scanner: *mut YR_SCANNER, flags: ::std::os::raw::c_int);
}
extern "C" {
pub fn yr_scanner_define_integer_variable(
scanner: *mut YR_SCANNER,
identifier: *const ::std::os::raw::c_char,
value: i64,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_scanner_define_boolean_variable(
scanner: *mut YR_SCANNER,
identifier: *const ::std::os::raw::c_char,
value: ::std::os::raw::c_int,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_scanner_define_float_variable(
scanner: *mut YR_SCANNER,
identifier: *const ::std::os::raw::c_char,
value: f64,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_scanner_define_string_variable(
scanner: *mut YR_SCANNER,
identifier: *const ::std::os::raw::c_char,
value: *const ::std::os::raw::c_char,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_scanner_scan_mem_blocks(
scanner: *mut YR_SCANNER,
iterator: *mut YR_MEMORY_BLOCK_ITERATOR,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_scanner_scan_mem(
scanner: *mut YR_SCANNER,
buffer: *const u8,
buffer_size: size_t,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_scanner_scan_file(
scanner: *mut YR_SCANNER,
filename: *const ::std::os::raw::c_char,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_scanner_scan_fd(
scanner: *mut YR_SCANNER,
fd: ::std::os::raw::c_int,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_scanner_scan_proc(
scanner: *mut YR_SCANNER,
pid: ::std::os::raw::c_int,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_scanner_last_error_rule(scanner: *mut YR_SCANNER) -> *mut YR_RULE;
}
extern "C" {
pub fn yr_scanner_last_error_string(scanner: *mut YR_SCANNER) -> *mut YR_STRING;
}
extern "C" {
pub fn yr_scanner_get_profiling_info(scanner: *mut YR_SCANNER) -> *mut YR_RULE_PROFILING_INFO;
}
extern "C" {
pub fn yr_scanner_reset_profiling_info(scanner: *mut YR_SCANNER);
}
extern "C" {
pub fn yr_scanner_print_profiling_info(scanner: *mut YR_SCANNER) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_rules_scan_mem_blocks(
rules: *mut YR_RULES,
iterator: *mut YR_MEMORY_BLOCK_ITERATOR,
flags: ::std::os::raw::c_int,
callback: YR_CALLBACK_FUNC,
user_data: *mut ::std::os::raw::c_void,
timeout: ::std::os::raw::c_int,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_rules_scan_mem(
rules: *mut YR_RULES,
buffer: *const u8,
buffer_size: size_t,
flags: ::std::os::raw::c_int,
callback: YR_CALLBACK_FUNC,
user_data: *mut ::std::os::raw::c_void,
timeout: ::std::os::raw::c_int,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_rules_scan_file(
rules: *mut YR_RULES,
filename: *const ::std::os::raw::c_char,
flags: ::std::os::raw::c_int,
callback: YR_CALLBACK_FUNC,
user_data: *mut ::std::os::raw::c_void,
timeout: ::std::os::raw::c_int,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_rules_scan_fd(
rules: *mut YR_RULES,
fd: ::std::os::raw::c_int,
flags: ::std::os::raw::c_int,
callback: YR_CALLBACK_FUNC,
user_data: *mut ::std::os::raw::c_void,
timeout: ::std::os::raw::c_int,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_rules_scan_proc(
rules: *mut YR_RULES,
pid: ::std::os::raw::c_int,
flags: ::std::os::raw::c_int,
callback: YR_CALLBACK_FUNC,
user_data: *mut ::std::os::raw::c_void,
timeout: ::std::os::raw::c_int,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_rules_save(
rules: *mut YR_RULES,
filename: *const ::std::os::raw::c_char,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_rules_save_stream(
rules: *mut YR_RULES,
stream: *mut YR_STREAM,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_rules_load(
filename: *const ::std::os::raw::c_char,
rules: *mut *mut YR_RULES,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_rules_load_stream(
stream: *mut YR_STREAM,
rules: *mut *mut YR_RULES,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_rules_destroy(rules: *mut YR_RULES) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_rules_define_integer_variable(
rules: *mut YR_RULES,
identifier: *const ::std::os::raw::c_char,
value: i64,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_rules_define_boolean_variable(
rules: *mut YR_RULES,
identifier: *const ::std::os::raw::c_char,
value: ::std::os::raw::c_int,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_rules_define_float_variable(
rules: *mut YR_RULES,
identifier: *const ::std::os::raw::c_char,
value: f64,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_rules_define_string_variable(
rules: *mut YR_RULES,
identifier: *const ::std::os::raw::c_char,
value: *const ::std::os::raw::c_char,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_rules_get_stats(
rules: *mut YR_RULES,
stats: *mut YR_RULES_STATS,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn yr_rule_disable(rule: *mut YR_RULE);
}
extern "C" {
pub fn yr_rule_enable(rule: *mut YR_RULE);
}
extern "C" {
pub fn yr_rules_from_arena(
arena: *mut YR_ARENA,
rules: *mut *mut YR_RULES,
) -> ::std::os::raw::c_int;
}