diff options
author | Justus Winter <justus@sequoia-pgp.org> | 2019-01-10 14:31:12 +0100 |
---|---|---|
committer | Justus Winter <justus@sequoia-pgp.org> | 2019-01-10 14:31:12 +0100 |
commit | 9699b4c705b1291ca8b4f2ec06b4d2f1a2949c10 (patch) | |
tree | aee65a9a54b9f1c250ab56ed89b732cef10013d8 /ffi/src/core.rs | |
parent | 3624ad398ec5d02ffa69fd769bd8e263560cbc1e (diff) |
ffi: Fix memory leaks in C tests.
Diffstat (limited to 'ffi/src/core.rs')
-rw-r--r-- | ffi/src/core.rs | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/ffi/src/core.rs b/ffi/src/core.rs index 14f11620..683f0d86 100644 --- a/ffi/src/core.rs +++ b/ffi/src/core.rs @@ -14,6 +14,10 @@ //! //! sq_context_t ctx; //! ctx = sq_context_new ("org.sequoia-pgp.example", NULL); +//! +//! /* Use Sequoia. */ +//! +//! sq_context_free (ctx); //! ``` //! //! A context can be configured using the builder pattern with @@ -28,6 +32,10 @@ //! cfg = sq_context_configure ("org.sequoia-pgp.example"); //! sq_config_network_policy (cfg, SQ_NETWORK_POLICY_OFFLINE); //! ctx = sq_config_build (cfg, NULL); +//! +//! /* Use Sequoia. */ +//! +//! sq_context_free (ctx); //! ``` use failure; |