Function es_copy_message

Source
pub unsafe extern "C" fn es_copy_message(
    msg: &es_message_t,
) -> *mut es_message_t
Available on macOS only.
Expand description

Retains an es_message_t, returning a non-const pointer to the given es_message_t for compatibility with existing code.

It is invalid to attempt to write to the returned es_message_t, despite being non-const, and doing so will result in a crash.

Deprecated in macOS 11+: Please use es_retain_message() to retain an es_message_t.

  • msg: The message to be retained
  • Returns a non-const pointer to the retained es_message_t

The caller must release the memory with es_free_message()