# HG changeset patch # User Mikael Berthe # Date 1444576755 -7200 # Node ID 1591518a33b9ecf0b18324c10a9e7b99ecbbef55 # Parent 189abf03ef24abfe4076f4672b59f22bff6a942f Minor change of the prototype for fingerprint_to_hex() diff -r 189abf03ef24 -r 1591518a33b9 mcabber/mcabber/utils.c --- a/mcabber/mcabber/utils.c Sun Oct 11 17:17:35 2015 +0200 +++ b/mcabber/mcabber/utils.c Sun Oct 11 17:19:15 2015 +0200 @@ -155,9 +155,10 @@ return g_strdup(fname); } -void fingerprint_to_hex(const unsigned char *fpr, char hex[48]) +void fingerprint_to_hex(const char *fprstr, char hex[48]) { int i; + const unsigned char *fpr = (const unsigned char *)fprstr; char *p; hex[0] = 0; diff -r 189abf03ef24 -r 1591518a33b9 mcabber/mcabber/utils.h --- a/mcabber/mcabber/utils.h Sun Oct 11 17:17:35 2015 +0200 +++ b/mcabber/mcabber/utils.h Sun Oct 11 17:19:15 2015 +0200 @@ -21,7 +21,7 @@ const char *resource); gboolean jid_equal(const char *jid1, const char *jid2); -void fingerprint_to_hex(const unsigned char *fpr, char hex[48]); +void fingerprint_to_hex(const char *fpr, char hex[48]); gboolean hex_to_fingerprint(const char *hex, char fpr[17]); void ut_init_debug(void); diff -r 189abf03ef24 -r 1591518a33b9 mcabber/mcabber/xmpp.c --- a/mcabber/mcabber/xmpp.c Sun Oct 11 17:17:35 2015 +0200 +++ b/mcabber/mcabber/xmpp.c Sun Oct 11 17:19:15 2015 +0200 @@ -715,8 +715,7 @@ break; case LM_SSL_STATUS_CERT_FINGERPRINT_MISMATCH: { char fpr[49] = {0}; - fingerprint_to_hex((const unsigned char*)lm_ssl_get_fingerprint(ssl), - fpr); + fingerprint_to_hex(lm_ssl_get_fingerprint(ssl), fpr); scr_LogPrint(LPRINT_LOGNORM, "Certificate fingerprint does not match expected fingerprint!"); scr_LogPrint(LPRINT_LOGNORM, "Remote fingerprint: %s", fpr);