Skip to content

Commit

Permalink
Merge pull request #865 from tamird/appease-lint
Browse files Browse the repository at this point in the history
aya: appease new nightly clippy lints
  • Loading branch information
tamird authored Jan 12, 2024
2 parents 53df49e + 7022528 commit 09851a2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion aya/src/bpf.rs
Original file line number Diff line number Diff line change
Expand Up @@ -533,7 +533,7 @@ impl<'a> BpfLoader<'a> {
let section = prog_obj.section.clone();
let obj = (prog_obj, function_obj);

let btf_fd = btf_fd.as_ref().map(Arc::clone);
let btf_fd = btf_fd.clone();
let program = if extensions.contains(name.as_str()) {
Program::Extension(Extension {
data: ProgramData::new(prog_name, obj, btf_fd, *verifier_log_level),
Expand Down
2 changes: 1 addition & 1 deletion aya/src/sys/fake.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ type SyscallFn = unsafe fn(Syscall<'_>) -> SysResult<c_long>;
#[cfg(test)]
thread_local! {
pub(crate) static TEST_SYSCALL: RefCell<SyscallFn> = RefCell::new(test_syscall);
pub(crate) static TEST_MMAP_RET: RefCell<*mut c_void> = RefCell::new(ptr::null_mut());
pub(crate) static TEST_MMAP_RET: RefCell<*mut c_void> = const { RefCell::new(ptr::null_mut()) };
}

#[cfg(test)]
Expand Down

0 comments on commit 09851a2

Please sign in to comment.