summaryrefslogtreecommitdiff
path: root/src/rexmpp.c
diff options
context:
space:
mode:
authordefanor <defanor@uberspace.net>2023-06-14 08:26:57 +0300
committerdefanor <defanor@uberspace.net>2023-06-14 08:26:57 +0300
commit931847c9c0d170410ec210ab558f3bbf6902355b (patch)
tree4d7bf90b30dc985edfbc09a5d0007b4aac8da533 /src/rexmpp.c
parent2d4110996bea53a9568b750d00d4dcdcc3907bc6 (diff)
Use more pointers to other structures from struct rexmpp
Instead of including them. Those structures can vary depending on configuration options, while for bindings it is easier if they stay the same, and are mere pointers. Besides, some of them may refer to opaque Rust-only structures in the future.
Diffstat (limited to 'src/rexmpp.c')
-rw-r--r--src/rexmpp.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/rexmpp.c b/src/rexmpp.c
index 7eede3f..a119d1f 100644
--- a/src/rexmpp.c
+++ b/src/rexmpp.c
@@ -670,6 +670,8 @@ rexmpp_err_t rexmpp_init (rexmpp_t *s,
xmlFreeParserCtxt(s->xml_parser);
return REXMPP_E_PGP;
}
+#else
+ s->pgp_ctx = NULL;
#endif
#ifdef HAVE_CURL
if (curl_global_init(CURL_GLOBAL_ALL) != 0) {
@@ -680,6 +682,8 @@ rexmpp_err_t rexmpp_init (rexmpp_t *s,
rexmpp_log(s, LOG_CRIT, "Failed to initialize curl_multi");
/* todo: free other structures and fail */
}
+#else
+ s->curl_multi = NULL;
#endif
return REXMPP_SUCCESS;