mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer-rs.git
synced 2024-11-22 09:31:06 +00:00
gstreamer/message: 2d attempt at printing src for Debug impl
1st attempt inc987bb0c
was reverted by89c4f68f
due to clippy "redundant clone" warning.
This commit is contained in:
parent
85e46f39f3
commit
0dce894b13
1 changed files with 8 additions and 1 deletions
|
@ -155,7 +155,14 @@ impl fmt::Debug for MessageRef {
|
||||||
CStr::from_ptr(type_).to_str().unwrap()
|
CStr::from_ptr(type_).to_str().unwrap()
|
||||||
})
|
})
|
||||||
.field("seqnum", seqnum)
|
.field("seqnum", seqnum)
|
||||||
.field("src", &self.get_src().map(|s| s.get_name()))
|
.field(
|
||||||
|
"src",
|
||||||
|
&self
|
||||||
|
.get_src()
|
||||||
|
.map(|s| s.get_name())
|
||||||
|
.as_ref()
|
||||||
|
.map(glib::GString::as_str),
|
||||||
|
)
|
||||||
.field("structure", &self.get_structure())
|
.field("structure", &self.get_structure())
|
||||||
.finish()
|
.finish()
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue