From db71602731da030c999f2821b2b4a64611b90b99 Mon Sep 17 00:00:00 2001 From: iphydf Date: Thu, 15 Dec 2016 17:35:54 +0000 Subject: Use `tox_options_set_*` instead of direct member access. Also added a `tox_options_copy` function for cloning an options object. This can be useful when creating several Tox instances with slightly varying options. --- toxcore/tox.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'toxcore/tox.h') diff --git a/toxcore/tox.h b/toxcore/tox.h index 5497d9e7..26378067 100644 --- a/toxcore/tox.h +++ b/toxcore/tox.h @@ -726,6 +726,12 @@ typedef enum TOX_ERR_OPTIONS_NEW { */ struct Tox_Options *tox_options_new(TOX_ERR_OPTIONS_NEW *error); +/** + * Allocates a new Tox_Options object and initialises it with the values from the + * passed object. + */ +void tox_options_copy(struct Tox_Options *options, const struct Tox_Options *rhs); + /** * Releases all resources associated with an options objects. * -- cgit v1.2.3