Skip to content

Commit

Permalink
Fix some clippy errors
Browse files Browse the repository at this point in the history
  • Loading branch information
zrax committed Jul 23, 2024
1 parent ac3a148 commit 3595357
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ serde_derive = "1.0"
serde_json = "1.0"
sha1 = "0.10"
tempfile = "3.3"
tokio = { version = "1.0", features = ["full"] }
tokio = { version = "1.0,<1.39", features = ["full"] }
toml = "0.5.11"
unicase = "2.6"
uuid = { version = "1.2.1", features = ["v4", "fast-rng"] }
2 changes: 1 addition & 1 deletion src/auth_srv/server.rs
Original file line number Diff line number Diff line change
Expand Up @@ -330,7 +330,7 @@ impl AuthServerWorker {
}).await
}
CliToAuth::AcctSetBillingTypeRequest { trans_id, .. } => {
self.send_message(AuthToCli::AcctSetRolesReply {
self.send_message(AuthToCli::AcctSetBillingTypeReply {
trans_id,
result: NetResultCode::NetNotSupported as i32,
}).await
Expand Down
3 changes: 2 additions & 1 deletion src/vault/vault_node.rs
Original file line number Diff line number Diff line change
Expand Up @@ -638,7 +638,8 @@ macro_rules! f_write_uuid {
macro_rules! f_write_blob {
($stream:ident, $fields:expr, $field:ident, $value:expr) => {
if ($fields & $field) != 0 {
$stream.write_u32::<LittleEndian>($value.len() as u32)?;
$stream.write_u32::<LittleEndian>(u32::try_from($value.len())
.context("Blob too large for stream")?)?;
$stream.write_all($value.as_slice())?;
}
}
Expand Down

0 comments on commit 3595357

Please sign in to comment.