From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [IPv6:2a01:7e0:0:424::9]) by lore.proxmox.com (Postfix) with ESMTPS id 0331F1FF15E for ; Mon, 5 Jan 2026 15:08:23 +0100 (CET) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 98DAC96E3; Mon, 5 Jan 2026 15:09:35 +0100 (CET) From: Kefu Chai To: pve-devel@lists.proxmox.com Date: Mon, 5 Jan 2026 22:08:13 +0800 Message-ID: <20260105140854.1216448-1-k.chai@proxmox.com> X-Mailer: git-send-email 2.47.3 MIME-Version: 1.0 X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1767622107378 X-SPAM-LEVEL: Spam detection results: 0 AWL 0.010 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record URIBL_SBL_A 0.1 Contains URL's A record listed in the Spamhaus SBL blocklist [188.114.96.3] Subject: [pve-devel] [PATCH proxmox-fuse-rs] Apply code formatting improvements for consistency X-BeenThere: pve-devel@lists.proxmox.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Proxmox VE development discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Proxmox VE development discussion Cc: Wolfgang Bumiller Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: pve-devel-bounces@lists.proxmox.com Sender: "pve-devel" Changes: - Sort imports alphabetically in use statements - Add semicolon after return statement in error path Rationale: 1. Import ordering: Alphabetically sorted imports improve code readability and reduce merge conflicts. Changed imports follow the pattern of sorting type/struct names before function names within the same crate. Examples: - anyhow::{Error, bail, format_err} (Error before bail/format_err) - tokio::signal::unix::{SignalKind, signal} (type before function) - sys::{EntryParam, ROOT_ID, ReplyBufState} (alphabetical order) 2. Semicolon after return: In src/fuse_fd.rs:376, added semicolon after the return statement for consistency with Rust style conventions. While optional for return statements, rustfmt and most style guides prefer explicit semicolons for uniformity. Impact: - No functional changes - purely stylistic improvements - Better alignment with standard Rust formatting tools (rustfmt) - Improved code consistency across the codebase Signed-off-by: Kefu Chai --- examples/tmpfs/main.rs | 4 ++-- src/fuse_fd.rs | 2 +- src/lib.rs | 2 +- src/session.rs | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/examples/tmpfs/main.rs b/examples/tmpfs/main.rs index 8ca7f9e..0f7e9c2 100644 --- a/examples/tmpfs/main.rs +++ b/examples/tmpfs/main.rs @@ -3,11 +3,11 @@ use std::ffi::OsStr; use std::path::Path; use std::{io, mem}; -use anyhow::{bail, format_err, Error}; +use anyhow::{Error, bail, format_err}; use futures::future::FutureExt; use futures::select; use futures::stream::TryStreamExt; -use tokio::signal::unix::{signal, SignalKind}; +use tokio::signal::unix::{SignalKind, signal}; use proxmox_fuse::requests::{self, FuseRequest, SetTime}; use proxmox_fuse::{EntryParam, Fuse, ReplyBufState, Request}; diff --git a/src/fuse_fd.rs b/src/fuse_fd.rs index 9205615..ae292b8 100644 --- a/src/fuse_fd.rs +++ b/src/fuse_fd.rs @@ -374,7 +374,7 @@ fn poll_thread_inner(poll: Arc, fd: RawFd, state: Arc) -> io:: return Err(io::Error::new( io::ErrorKind::Other, "epoll_wait returned unexpected events", - )) + )); } } } diff --git a/src/lib.rs b/src/lib.rs index df509ec..32abbe9 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -5,7 +5,7 @@ pub(crate) mod sys; pub(crate) mod util; #[doc(inline)] -pub use sys::{EntryParam, ReplyBufState, ROOT_ID}; +pub use sys::{EntryParam, ROOT_ID, ReplyBufState}; #[doc(inline)] pub use requests::Request; diff --git a/src/session.rs b/src/session.rs index a38593e..62a8a9e 100644 --- a/src/session.rs +++ b/src/session.rs @@ -9,7 +9,7 @@ use std::sync::Arc; use std::task::{Context, Poll}; use std::{io, mem}; -use anyhow::{bail, format_err, Error}; +use anyhow::{Error, bail, format_err}; use futures::ready; use futures::stream::{FusedStream, Stream}; -- 2.47.3 _______________________________________________ pve-devel mailing list pve-devel@lists.proxmox.com https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel