From 1e04f809a2ce180753cf9fb3e15030732f5836b7 Mon Sep 17 00:00:00 2001 From: "tien.xuan.vo" Date: Thu, 26 Sep 2024 14:51:14 +0700 Subject: [PATCH] docs: Update safety comments --- rust/pact_ffi/src/mock_server/handles.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/rust/pact_ffi/src/mock_server/handles.rs b/rust/pact_ffi/src/mock_server/handles.rs index 56da1796..3453b59c 100644 --- a/rust/pact_ffi/src/mock_server/handles.rs +++ b/rust/pact_ffi/src/mock_server/handles.rs @@ -2523,7 +2523,8 @@ ffi_fn!{ /// /// # Safety /// - /// The comments parameter must be a valid pointer to a NULL terminated UTF-8, + /// The key parameter must be a valid pointer to a NULL terminated UTF-8. + /// The value parameter must be a valid pointer to a NULL terminated UTF-8, /// or NULL if the comment is to be cleared. fn pactffi_set_comment(interaction: InteractionHandle, key: *const c_char, value: *const c_char) -> bool { let key = match convert_cstr("key", key) { @@ -2578,8 +2579,7 @@ ffi_fn!{ /// /// # Safety /// - /// The comments parameter must be a valid pointer to a NULL terminated UTF-8, - /// or NULL if the comment is to be cleared. + /// The comment parameter must be a valid pointer to a NULL terminated UTF-8. fn pactffi_add_text_comment(interaction: InteractionHandle, comment: *const c_char) -> bool { let comment = match convert_cstr("comment", comment) { Some(comment) => comment,