| Crates.io | fifd-rs |
| lib.rs | fifd-rs |
| version | 0.2.2 |
| created_at | 2025-04-30 06:18:01.391893+00 |
| updated_at | 2025-05-21 11:28:50.666386+00 |
| description | This is a Rust implementation of the Go library [IncSW/fifd](https://github.com/IncSW/fifd). `fifd` is used to find file descriptors. |
| homepage | |
| repository | https://github.com/zhaopengme/fifd-rs |
| max_upload_size | |
| id | 1654506 |
| size | 73,803 |
This is a Rust implementation of the Go library IncSW/fifd. fifd is used to find file descriptors.
fifd (Find Invalid File Descriptors) is a utility library for detecting and finding invalid or unexpectedly open file descriptors in a process. This Rust version aims to provide similar functionality to the original Go version, leveraging Rust's safety and performance benefits.
Add this library to your Cargo.toml file:
[dependencies]
fifd = "0.1.0" # Please replace with the latest version
Then run cargo build.
// Basic usage example (adjust according to the actual API)
// use fifd;
fn main() {
// Find invalid file descriptors for the current process
// match fifd::find_invalid_fds() {
// Ok(fds) => {
// if fds.is_empty() {
// println!("No invalid file descriptors found.");
// } else {
// println!("Found the following invalid file descriptors: {:?}", fds);
// }
// }
// Err(e) => {
// eprintln!("Error finding file descriptors: {}", e);
// }
// }
println!("fifd-rs: Feature under development."); // Temporary placeholder
}
(Note: The usage example above is hypothetical. Please modify it according to the library's actual API.)
This project is licensed under the [License Name] License. See the LICENSE file for details. (It is recommended to keep the license consistent with the original Go project, e.g., MIT or Apache 2.0).