From 1d21f2de35633113c38692a4fcb7e0481c96fd08 Mon Sep 17 00:00:00 2001 From: KyleMiles Date: Fri, 7 Oct 2022 15:55:43 -0400 Subject: Remove default load settings; Move settings `analysis.debugInfoInternal` and `loader.debugInfoExternal` to `analysis.debugInfo.internal` and `analysis.debugInfo.external` --- rust/src/binaryview.rs | 28 +++------------------------- 1 file changed, 3 insertions(+), 25 deletions(-) (limited to 'rust/src/binaryview.rs') diff --git a/rust/src/binaryview.rs b/rust/src/binaryview.rs index bf9aea9b..b0379aae 100644 --- a/rust/src/binaryview.rs +++ b/rust/src/binaryview.rs @@ -690,28 +690,6 @@ pub trait BinaryViewExt: BinaryViewBase { }; } - fn get_default_load_settings( - &self, - view_type_name: S, - settings: &Settings, - ) -> Result> { - let view_type_name = view_type_name.into_bytes_with_nul(); - - let settings_handle = unsafe { - BNBinaryViewGetDefaultLoadSettings( - self.as_ref().handle, - view_type_name.as_ref().as_ptr() as *mut _, - settings.handle, - ) - }; - - if settings_handle.is_null() { - Err(()) - } else { - Ok(unsafe { Settings::from_raw(settings_handle) }) - } - } - /// Creates a new [TagType] and adds it to the view. /// /// # Arguments @@ -934,7 +912,7 @@ impl BinaryView { let file = filename.into_bytes_with_nul(); let handle = unsafe { - BNCreateBinaryDataViewFromFilename(meta.handle, file.as_ref().as_ptr() as *mut _, true) + BNCreateBinaryDataViewFromFilename(meta.handle, file.as_ref().as_ptr() as *mut _) }; if handle.is_null() { @@ -946,7 +924,7 @@ impl BinaryView { pub fn from_accessor(meta: &FileMetadata, file: &mut FileAccessor) -> Result> { let handle = unsafe { - BNCreateBinaryDataViewFromFile(meta.handle, &mut file.api_object as *mut _, true) + BNCreateBinaryDataViewFromFile(meta.handle, &mut file.api_object as *mut _) }; if handle.is_null() { @@ -958,7 +936,7 @@ impl BinaryView { pub fn from_data(meta: &FileMetadata, data: &[u8]) -> Result> { let handle = unsafe { - BNCreateBinaryDataViewFromData(meta.handle, data.as_ptr() as *mut _, data.len(), true) + BNCreateBinaryDataViewFromData(meta.handle, data.as_ptr() as *mut _, data.len()) }; if handle.is_null() { -- cgit v1.3.1