Skip to content

Commit

Permalink
Improve Debug for AF_ALG structures
Browse files Browse the repository at this point in the history
  • Loading branch information
Gleb Pomykalov committed Feb 19, 2019
1 parent c35d8fb commit ae2663a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/unix/notbsd/android/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -492,7 +492,7 @@ cfg_if! {
.field("salg_type", &self.salg_type)
.field("salg_feat", &self.salg_feat)
.field("salg_mask", &self.salg_mask)
// .field("salg_name", &self.salg_name)
.field("salg_name", &self.salg_name.iter().collect::<Vec<_>>())
.finish()
}
}
Expand Down Expand Up @@ -529,7 +529,7 @@ cfg_if! {
impl ::fmt::Debug for af_alg_iv {
fn fmt(&self, f: &mut ::fmt::Formatter) -> ::fmt::Result {
f.debug_struct("af_alg_iv")
// .field("iv", self.as_slice())
.field("iv", &self.as_slice().iter().collect::<Vec<_>>())
.finish()
}
}
Expand Down
4 changes: 2 additions & 2 deletions src/unix/notbsd/linux/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -711,7 +711,7 @@ cfg_if! {
.field("salg_type", &self.salg_type)
.field("salg_feat", &self.salg_feat)
.field("salg_mask", &self.salg_mask)
// .field("salg_name", &self.salg_name)
.field("salg_name", &self.salg_name.iter().collect::<Vec<_>>())
.finish()
}
}
Expand Down Expand Up @@ -748,7 +748,7 @@ cfg_if! {
impl ::fmt::Debug for af_alg_iv {
fn fmt(&self, f: &mut ::fmt::Formatter) -> ::fmt::Result {
f.debug_struct("af_alg_iv")
// .field("iv", self.as_slice())
.field("iv", &self.as_slice().iter().collect::<Vec<_>>())
.finish()
}
}
Expand Down

0 comments on commit ae2663a

Please sign in to comment.