fix: cargo formatting for ci/cd
This commit is contained in:
@@ -293,9 +293,7 @@ impl LiveThreatFeeds {
|
||||
indicator.get("type").and_then(|t| t.as_str()),
|
||||
) {
|
||||
// Map OTX threat level to our scale
|
||||
let threat_level = indicator
|
||||
.get("expiration").map(|_| 4)
|
||||
.unwrap_or(3);
|
||||
let threat_level = indicator.get("expiration").map(|_| 4).unwrap_or(3);
|
||||
|
||||
iocs.push(CachedIOC {
|
||||
value: value.to_string(),
|
||||
|
||||
@@ -383,11 +383,7 @@ mod platform {
|
||||
fn proc_pidpath(pid: c_int, buffer: *mut c_void, buffersize: u32) -> c_int;
|
||||
}
|
||||
|
||||
let ret = proc_pidpath(
|
||||
pid as c_int,
|
||||
buffer.as_mut_ptr() as *mut c_void,
|
||||
size,
|
||||
);
|
||||
let ret = proc_pidpath(pid as c_int, buffer.as_mut_ptr() as *mut c_void, size);
|
||||
|
||||
if ret > 0 {
|
||||
let path_bytes = &buffer[..ret as usize];
|
||||
|
||||
@@ -216,7 +216,8 @@ impl DynamicYaraEngine {
|
||||
#[cfg(not(feature = "yara-scanning"))]
|
||||
pub fn compile_rules(&mut self) -> Result<usize, GhostError> {
|
||||
Err(GhostError::Configuration {
|
||||
message: "YARA scanning is not enabled. Build with --features yara-scanning to enable.".to_string(),
|
||||
message: "YARA scanning is not enabled. Build with --features yara-scanning to enable."
|
||||
.to_string(),
|
||||
})
|
||||
}
|
||||
|
||||
@@ -330,7 +331,8 @@ impl DynamicYaraEngine {
|
||||
_memory_regions: &[MemoryRegion],
|
||||
) -> Result<YaraScanResult, GhostError> {
|
||||
Err(GhostError::Configuration {
|
||||
message: "YARA scanning is not enabled. Build with --features yara-scanning to enable.".to_string(),
|
||||
message: "YARA scanning is not enabled. Build with --features yara-scanning to enable."
|
||||
.to_string(),
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user