about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorJames Booth <boothj5@gmail.com>2015-09-22 21:55:46 +0100
committerJames Booth <boothj5@gmail.com>2015-09-22 21:55:46 +0100
commit9a53854a1d196e79a031c28b7a6013ac41c58c4c (patch)
tree2e0037d4d8d20a16fc8ccd71e956851d9424c07a
parent9414ad268d79ba3d0e75ef5fbe0e379c4462893d (diff)
downloadprofani-tty-9a53854a1d196e79a031c28b7a6013ac41c58c4c.tar.gz
Added conditionals for libmesode cert verification
-rw-r--r--src/xmpp/connection.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/xmpp/connection.c b/src/xmpp/connection.c
index be60ad21..c6d04079 100644
--- a/src/xmpp/connection.c
+++ b/src/xmpp/connection.c
@@ -360,12 +360,14 @@ _connection_free_session_data(void)
     presence_clear_sub_requests();
 }
 
+#ifdef HAVE_LIBMESODE
 static int
 _connection_certfail_cb(const char * const certname, const char * const certfp,
     char * const notbefore, const char * const notafter, const char * const errormsg)
 {
     return sv_ev_certfail(errormsg, certname, certfp, notbefore, notafter);
 }
+#endif
 
 static jabber_conn_status_t
 _jabber_connect(const char * const fulljid, const char * const passwd,
@@ -417,8 +419,13 @@ _jabber_connect(const char * const fulljid, const char * const passwd,
         xmpp_conn_disable_tls(jabber_conn.conn);
     }
 
+#ifdef HAVE_LIBMESODE
     int connect_status = xmpp_connect_client(jabber_conn.conn, altdomain, port,
         _connection_certfail_cb, _connection_handler, jabber_conn.ctx);
+#else
+    int connect_status = xmpp_connect_client(jabber_conn.conn, altdomain, port,
+        _connection_handler, jabber_conn.ctx);
+#endif
 
     if (connect_status == 0)
         jabber_conn.conn_status = JABBER_CONNECTING;
^
bc643692 ^
6f65d591 ^

fb942da8 ^
6f65d591 ^
fb942da8 ^
1fd41772 ^
fb942da8 ^
1fd41772 ^






e80fd05f ^














1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47