From 6fe451c56514c97798a53cc6c63cb012f7628799 Mon Sep 17 00:00:00 2001 From: eclipse-zenoh-bot <61247838+eclipse-zenoh-bot@users.noreply.github.com> Date: Thu, 5 Sep 2024 13:07:53 +0200 Subject: [PATCH] build: Sync with eclipse-zenoh/zenoh@5dc5f85 from 2024-09-02 (#639) Co-authored-by: eclipse-zenoh-bot --- Cargo.lock | 68 +++++++++++++++++++---------------------- include/zenoh_commons.h | 6 ++++ include/zenoh_macros.h | 26 ++++++++-------- 3 files changed, 50 insertions(+), 50 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index ed43560a5..38a7b95c9 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1885,7 +1885,7 @@ dependencies = [ "pin-project-lite", "quinn-proto", "quinn-udp", - "rustc-hash 2.0.0", + "rustc-hash", "rustls", "socket2 0.5.7", "thiserror", @@ -1895,14 +1895,14 @@ dependencies = [ [[package]] name = "quinn-proto" -version = "0.11.3" +version = "0.11.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ddf517c03a109db8100448a4be38d498df8a210a99fe0e1b9eaf39e78c640efe" +checksum = "fadfaed2cd7f389d0161bb73eeb07b7b78f8691047a6f3e73caaeae55310a4a6" dependencies = [ "bytes", "rand", "ring", - "rustc-hash 1.1.0", + "rustc-hash", "rustls", "rustls-platform-verifier", "slab", @@ -2091,12 +2091,6 @@ version = "0.1.23" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d626bb9dae77e28219937af045c257c28bfd3f69333c512553507f5f9798cb76" -[[package]] -name = "rustc-hash" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08d43f7aa6b08d49f382cde6a7982047c3426db949b1424bc4b7ec9ae12c6ce2" - [[package]] name = "rustc-hash" version = "2.0.0" @@ -3511,7 +3505,7 @@ dependencies = [ [[package]] name = "zenoh" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "ahash", "async-trait", @@ -3569,7 +3563,7 @@ dependencies = [ [[package]] name = "zenoh-buffers" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "zenoh-collections", ] @@ -3607,7 +3601,7 @@ dependencies = [ [[package]] name = "zenoh-codec" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "serde", "tracing", @@ -3620,12 +3614,12 @@ dependencies = [ [[package]] name = "zenoh-collections" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" [[package]] name = "zenoh-config" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "flume", "json5", @@ -3647,7 +3641,7 @@ dependencies = [ [[package]] name = "zenoh-core" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "async-global-executor", "lazy_static", @@ -3659,7 +3653,7 @@ dependencies = [ [[package]] name = "zenoh-crypto" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "aes", "hmac", @@ -3672,7 +3666,7 @@ dependencies = [ [[package]] name = "zenoh-ext" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "bincode", "flume", @@ -3691,7 +3685,7 @@ dependencies = [ [[package]] name = "zenoh-keyexpr" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "hashbrown 0.14.5", "keyed-set", @@ -3705,7 +3699,7 @@ dependencies = [ [[package]] name = "zenoh-link" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "async-trait", "zenoh-config", @@ -3723,7 +3717,7 @@ dependencies = [ [[package]] name = "zenoh-link-commons" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "async-trait", "flume", @@ -3748,7 +3742,7 @@ dependencies = [ [[package]] name = "zenoh-link-quic" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "async-trait", "base64 0.22.1", @@ -3779,7 +3773,7 @@ dependencies = [ [[package]] name = "zenoh-link-tcp" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "async-trait", "socket2 0.5.7", @@ -3798,7 +3792,7 @@ dependencies = [ [[package]] name = "zenoh-link-tls" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "async-trait", "base64 0.22.1", @@ -3829,7 +3823,7 @@ dependencies = [ [[package]] name = "zenoh-link-udp" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "async-trait", "socket2 0.5.7", @@ -3850,7 +3844,7 @@ dependencies = [ [[package]] name = "zenoh-link-unixsock_stream" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "async-trait", "futures", @@ -3870,7 +3864,7 @@ dependencies = [ [[package]] name = "zenoh-link-ws" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "async-trait", "futures-util", @@ -3891,7 +3885,7 @@ dependencies = [ [[package]] name = "zenoh-macros" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "proc-macro2", "quote", @@ -3902,7 +3896,7 @@ dependencies = [ [[package]] name = "zenoh-plugin-trait" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "libloading", "serde", @@ -3917,7 +3911,7 @@ dependencies = [ [[package]] name = "zenoh-protocol" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "const_format", "rand", @@ -3932,7 +3926,7 @@ dependencies = [ [[package]] name = "zenoh-result" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "anyhow", ] @@ -3940,7 +3934,7 @@ dependencies = [ [[package]] name = "zenoh-runtime" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "futures", "lazy_static", @@ -3955,7 +3949,7 @@ dependencies = [ [[package]] name = "zenoh-shm" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "async-trait", "bincode", @@ -3979,7 +3973,7 @@ dependencies = [ [[package]] name = "zenoh-sync" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "event-listener 5.3.1", "futures", @@ -3993,7 +3987,7 @@ dependencies = [ [[package]] name = "zenoh-task" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "futures", "tokio", @@ -4006,7 +4000,7 @@ dependencies = [ [[package]] name = "zenoh-transport" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "async-trait", "crossbeam-utils", @@ -4041,7 +4035,7 @@ dependencies = [ [[package]] name = "zenoh-util" version = "1.0.0-dev" -source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#983908b35b2a5bc8830b8eccec8025e62d69dc7f" +source = "git+https://github.com/eclipse-zenoh/zenoh.git?branch=main#60af27464ec3412ec1eba27d4881a8c378997330" dependencies = [ "async-trait", "const_format", diff --git a/include/zenoh_commons.h b/include/zenoh_commons.h index 386c5582b..1b8f1a408 100644 --- a/include/zenoh_commons.h +++ b/include/zenoh_commons.h @@ -2613,6 +2613,12 @@ ZENOHC_API enum z_whatami_t z_hello_whatami(const struct z_loaned_hello_t *this_ #if defined(UNSTABLE) ZENOHC_API z_id_t z_hello_zid(const struct z_loaned_hello_t *this_); #endif +/** + * Formats the `z_id_t` into 16-digit hex string (LSB-first order) + */ +#if defined(UNSTABLE) +ZENOHC_API void z_id_to_string(const z_id_t *zid, struct z_owned_string_t *dst); +#endif /** * Fetches the Zenoh IDs of all connected peers. * diff --git a/include/zenoh_macros.h b/include/zenoh_macros.h index 8123e8af9..2919ffcc5 100644 --- a/include/zenoh_macros.h +++ b/include/zenoh_macros.h @@ -657,43 +657,43 @@ inline void z_call(const z_loaned_closure_sample_t* closure, const z_loaned_samp z_closure_sample_call(closure, sample); }; -extern "C" typedef void (*z_closure_drop_callback_t)(void*); +extern "C" using z_closure_drop_callback_t = void(void*); -extern "C" typedef void (*z_closure_hello_callback_t)(const z_loaned_hello_t*, void*); +extern "C" using z_closure_hello_callback_t = void(const z_loaned_hello_t*, void*); inline void z_closure( z_owned_closure_hello_t* closure, - z_closure_hello_callback_t call, - z_closure_drop_callback_t drop, + z_closure_hello_callback_t* call, + z_closure_drop_callback_t* drop, void *context) { closure->context = context; closure->drop = drop; closure->call = call; }; -extern "C" typedef void (*z_closure_query_callback_t)(const z_loaned_query_t*, void*); +extern "C" using z_closure_query_callback_t = void(const z_loaned_query_t*, void*); inline void z_closure( z_owned_closure_query_t* closure, - z_closure_query_callback_t call, - z_closure_drop_callback_t drop, + z_closure_query_callback_t* call, + z_closure_drop_callback_t* drop, void *context) { closure->context = context; closure->drop = drop; closure->call = call; }; -extern "C" typedef void (*z_closure_reply_callback_t)(const z_loaned_reply_t*, void*); +extern "C" using z_closure_reply_callback_t = void(const z_loaned_reply_t*, void*); inline void z_closure( z_owned_closure_reply_t* closure, - z_closure_reply_callback_t call, - z_closure_drop_callback_t drop, + z_closure_reply_callback_t* call, + z_closure_drop_callback_t* drop, void *context) { closure->context = context; closure->drop = drop; closure->call = call; }; -extern "C" typedef void (*z_closure_sample_callback_t)(const z_loaned_sample_t*, void*); +extern "C" using z_closure_sample_callback_t = void(const z_loaned_sample_t*, void*); inline void z_closure( z_owned_closure_sample_t* closure, - z_closure_sample_callback_t call, - z_closure_drop_callback_t drop, + z_closure_sample_callback_t* call, + z_closure_drop_callback_t* drop, void *context) { closure->context = context; closure->drop = drop;