rust_types.h 490 B

12345678910111213141516171819202122
  1. /* Copyright (c) 2017, The Tor Project, Inc. */
  2. /* See LICENSE for licensing information */
  3. /**
  4. * \file rust_types.h
  5. * \brief Headers for rust_types.c
  6. **/
  7. #include "or.h"
  8. #ifndef TOR_RUST_TYPES_H
  9. #define TOR_RUST_TYPES_H
  10. /* This type is used to clearly mark strings that have been allocated in Rust,
  11. * and therefore strictly need to use the free_rust_str method to free.
  12. */
  13. typedef char *rust_str_ref_t;
  14. void move_rust_str_to_c_and_free(rust_str_ref_t src, char **dest);
  15. #endif