Skip to content

Commit dcd043e

Browse files
fix v2
1 parent b58c5d5 commit dcd043e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

relay-cabi/src/core.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ impl From<Uuid> for RelayUuid {
135135
#[unsafe(no_mangle)]
136136
#[relay_ffi::catch_unwind]
137137
pub unsafe extern "C" fn relay_uuid_is_nil(uuid: *const RelayUuid) -> bool {
138-
if let Ok(uuid) = Uuid::from_slice(unsafe { &(*uuid).data[..] }) {
138+
if let Ok(uuid) = Uuid::from_slice(unsafe { &(&(*uuid).data)[..] }) {
139139
uuid == Uuid::nil()
140140
} else {
141141
false
@@ -149,7 +149,7 @@ pub unsafe extern "C" fn relay_uuid_is_nil(uuid: *const RelayUuid) -> bool {
149149
#[unsafe(no_mangle)]
150150
#[relay_ffi::catch_unwind]
151151
pub unsafe extern "C" fn relay_uuid_to_str(uuid: *const RelayUuid) -> RelayStr {
152-
let uuid = Uuid::from_slice(unsafe { &(*uuid).data[..] }).unwrap_or_else(|_| Uuid::nil());
152+
let uuid = Uuid::from_slice(unsafe { &(&(*uuid).data)[..] }).unwrap_or_else(|_| Uuid::nil());
153153
RelayStr::from_string(uuid.as_hyphenated().to_string())
154154
}
155155

0 commit comments

Comments
 (0)