mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-04-28 19:54:35 +00:00
agent: fix clippy warnings caused by protobuf3
Fix warnings introduced by protobuf upgrade. Signed-off-by: Tim Zhang <tim@hyper.sh>
This commit is contained in:
parent
4849c56faa
commit
2e3f19af92
@ -211,7 +211,7 @@ async fn ephemeral_storage_handler(
|
||||
// By now we only support one option field: "fsGroup" which
|
||||
// isn't an valid mount option, thus we should remove it when
|
||||
// do mount.
|
||||
if storage.options.len() > 0 {
|
||||
if !storage.options.is_empty() {
|
||||
// ephemeral_storage didn't support mount options except fsGroup.
|
||||
let mut new_storage = storage.clone();
|
||||
new_storage.options = Default::default();
|
||||
|
@ -2034,7 +2034,7 @@ fn load_kernel_module(module: &protocols::agent::KernelModule) -> Result<()> {
|
||||
|
||||
let mut args = vec!["-v".to_string(), module.name.clone()];
|
||||
|
||||
if module.parameters.len() > 0 {
|
||||
if !module.parameters.is_empty() {
|
||||
args.extend(module.parameters.to_vec())
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user