guillaumepellegrino / acsrs

A simple ACS written in Rust
GNU General Public License v3.0
5 stars 4 forks source link

fix clippy warnings and add clippy to workflow #3

Closed jarlah closed 1 year ago

jarlah commented 1 year ago

cargo clippy --fix --allow-dirty plus a couple of manual changes and test. added clippy run after fmt in workflow

jarlah commented 1 year ago

@guillaumepellegrino clippy now fails because of this possible bug:

error: calls to `std::mem::drop` with a reference instead of an owned value. Dropping a reference does nothing
  --> src/utils.rs:91:5
   |
91 |     drop(child_stdin);
   |     ^^^^^^^^^^^^^^^^^
   |
note: argument has type `&mut std::process::ChildStdin`
  --> src/utils.rs:91:10
   |
91 |     drop(child_stdin);
   |          ^^^^^^^^^^^
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#drop_ref
   = note: `#[deny(clippy::drop_ref)]` on by default

error: could not compile `acsrs` due to previous error
Error: Process completed with exit code 101.

EDIT: fixed

jarlah commented 1 year ago

I'm merging this, as it doesn't introduce any functional changes. I tested both the server and cli roughly. Server starts up and generates certificates.