diff --git a/gio/src/unix_socket_address.rs b/gio/src/unix_socket_address.rs index 82ce5b43bea7..e126d9398d23 100644 --- a/gio/src/unix_socket_address.rs +++ b/gio/src/unix_socket_address.rs @@ -47,7 +47,13 @@ impl UnixSocketAddress { let type_ = address_type.to_type(); let (path, len) = match address_type { - Path(path) => (path.to_glib_none().0, -1), + Path(path) => { + unsafe { + let p = std::ffi::CStr::from_ptr(path.to_glib_none().0); + panic!("{address_type:?} {p:?}"); + } + (path.to_glib_none().0, -1) + } Abstract(path) | AbstractPadded(path) => ( path.to_glib_none().0 as *mut libc::c_char, path.len() as i32, @@ -55,6 +61,9 @@ impl UnixSocketAddress { Anonymous => (ptr::null_mut(), 0), }; unsafe { + let p = std::ffi::CStr::from_ptr(path); + panic!("{address_type:?} {p:?} {len}"); + SocketAddress::from_glib_full(ffi::g_unix_socket_address_new_with_type( path, len,