mirror of
https://github.com/logos-messaging/logos-messaging-rust-bindings.git
synced 2026-01-09 17:33:10 +00:00
chore: update go-waku version
This commit is contained in:
parent
e4672df292
commit
e52471bdfb
@ -69,8 +69,8 @@ fn retrieve_history(
|
|||||||
let peer = node_handle
|
let peer = node_handle
|
||||||
.peers()?
|
.peers()?
|
||||||
.iter()
|
.iter()
|
||||||
|
.find(|&peer| peer.peer_id() != &self_id)
|
||||||
.cloned()
|
.cloned()
|
||||||
.find(|peer| peer.peer_id() != &self_id)
|
|
||||||
.unwrap();
|
.unwrap();
|
||||||
|
|
||||||
let result = node_handle.store_query(
|
let result = node_handle.store_query(
|
||||||
|
|||||||
@ -15,16 +15,16 @@ use crate::utils::{get_trampoline, handle_json_response, handle_no_response, han
|
|||||||
/// As per the [specification](https://rfc.vac.dev/spec/36/#extern-char-waku_content_topicchar-applicationname-unsigned-int-applicationversion-char-contenttopicname-char-encoding)
|
/// As per the [specification](https://rfc.vac.dev/spec/36/#extern-char-waku_content_topicchar-applicationname-unsigned-int-applicationversion-char-contenttopicname-char-encoding)
|
||||||
pub fn waku_create_content_topic(
|
pub fn waku_create_content_topic(
|
||||||
application_name: &str,
|
application_name: &str,
|
||||||
application_version: usize,
|
application_version: &str,
|
||||||
content_topic_name: &str,
|
content_topic_name: &str,
|
||||||
encoding: Encoding,
|
encoding: Encoding,
|
||||||
) -> WakuContentTopic {
|
) -> WakuContentTopic {
|
||||||
let application_name_ptr = CString::new(application_name)
|
let application_name_ptr = CString::new(application_name)
|
||||||
.expect("Application name should always transform to CString")
|
.expect("Application name should always transform to CString")
|
||||||
.into_raw();
|
.into_raw();
|
||||||
let application_version = application_version
|
let application_version_ptr = CString::new(application_version)
|
||||||
.try_into()
|
.expect("Application version should always transform to CString")
|
||||||
.expect("Version should fit within an u32");
|
.into_raw();
|
||||||
let content_topic_name_ptr = CString::new(content_topic_name)
|
let content_topic_name_ptr = CString::new(content_topic_name)
|
||||||
.expect("Content topic should always transform to CString")
|
.expect("Content topic should always transform to CString")
|
||||||
.into_raw();
|
.into_raw();
|
||||||
@ -39,7 +39,7 @@ pub fn waku_create_content_topic(
|
|||||||
let cb = get_trampoline(&closure);
|
let cb = get_trampoline(&closure);
|
||||||
let out = waku_sys::waku_content_topic(
|
let out = waku_sys::waku_content_topic(
|
||||||
application_name_ptr,
|
application_name_ptr,
|
||||||
application_version,
|
application_version_ptr,
|
||||||
content_topic_name_ptr,
|
content_topic_name_ptr,
|
||||||
encoding_ptr,
|
encoding_ptr,
|
||||||
cb,
|
cb,
|
||||||
@ -47,6 +47,7 @@ pub fn waku_create_content_topic(
|
|||||||
);
|
);
|
||||||
|
|
||||||
drop(CString::from_raw(application_name_ptr));
|
drop(CString::from_raw(application_name_ptr));
|
||||||
|
drop(CString::from_raw(application_version_ptr));
|
||||||
drop(CString::from_raw(content_topic_name_ptr));
|
drop(CString::from_raw(content_topic_name_ptr));
|
||||||
drop(CString::from_raw(encoding_ptr));
|
drop(CString::from_raw(encoding_ptr));
|
||||||
|
|
||||||
|
|||||||
@ -1 +1 @@
|
|||||||
Subproject commit 02f2800b046094f73d1011081daef7d897126687
|
Subproject commit e340337d64622d22cb94a969255efe4e36637df0
|
||||||
Loading…
x
Reference in New Issue
Block a user