]> git.bitcoin.ninja Git - ldk-c-bindings/commit
Resolve issues with Str introduced when it became ownable
authorMatt Corallo <git@bluematt.me>
Fri, 30 Apr 2021 23:09:05 +0000 (23:09 +0000)
committerMatt Corallo <git@bluematt.me>
Fri, 30 Apr 2021 23:41:31 +0000 (23:41 +0000)
commitdb0ed2ef02f28a8b393eb3640959587bfe1a7e52
treec9b39e20c5ea918e15112e6c3516b1412c4c4d81
parent7ae0ad1e6274e614ec82fc84f317db09884b4beb
Resolve issues with Str introduced when it became ownable

When converting from a Str to an &str, we previously took ownership
of the Str, copied the pointer to its characters to an &str and
returned the &str. This made the returned bytes always unreadable.

Further, there is now no reason to use Vec_u8Z for owned Strs, so
we swap for Str as well.
c-bindings-gen/src/main.rs
c-bindings-gen/src/types.rs
lightning-c-bindings/src/c_types/mod.rs