diff options
Diffstat (limited to 'src/plugins/irc')
-rw-r--r-- | src/plugins/irc/irc-server.c | 44 | ||||
-rw-r--r-- | src/plugins/irc/irc-server.h | 1 |
2 files changed, 22 insertions, 23 deletions
diff --git a/src/plugins/irc/irc-server.c b/src/plugins/irc/irc-server.c index 5f468d0eb..1d0c50e90 100644 --- a/src/plugins/irc/irc-server.c +++ b/src/plugins/irc/irc-server.c @@ -404,6 +404,28 @@ irc_server_eval_expression (struct t_irc_server *server, const char *string) } /* + * Searches for a fingerprint digest algorithm with the size (in bits). + * + * Returns index of algo in enum t_irc_fingerprint_digest_algo, + * -1 if not found. + */ + +int +irc_server_fingerprint_search_algo_with_size (int size) +{ + int i; + + for (i = 0; i < IRC_FINGERPRINT_NUM_ALGOS; i++) + { + if (irc_fingerprint_digest_algos_size[i] == size) + return i; + } + + /* digest algorithm not found */ + return -1; +} + +/* * Evaluates and returns the fingerprint. * * Returns the evaluated fingerprint, NULL if the fingerprint option is @@ -4774,28 +4796,6 @@ irc_server_create_buffer (struct t_irc_server *server) } /* - * Searches for a fingerprint digest algorithm with the size (in bits). - * - * Returns index of algo in enum t_irc_fingerprint_digest_algo, - * -1 if not found. - */ - -int -irc_server_fingerprint_search_algo_with_size (int size) -{ - int i; - - for (i = 0; i < IRC_FINGERPRINT_NUM_ALGOS; i++) - { - if (irc_fingerprint_digest_algos_size[i] == size) - return i; - } - - /* digest algorithm not found */ - return -1; -} - -/* * Returns a string with sizes of allowed fingerprint, * in number of hexadecimal digits (== bits / 4). * diff --git a/src/plugins/irc/irc-server.h b/src/plugins/irc/irc-server.h index f26a4437e..d34cb31d0 100644 --- a/src/plugins/irc/irc-server.h +++ b/src/plugins/irc/irc-server.h @@ -418,7 +418,6 @@ extern void irc_server_msgq_add_buffer (struct t_irc_server *server, extern void irc_server_msgq_flush (); extern void irc_server_set_buffer_title (struct t_irc_server *server); extern struct t_gui_buffer *irc_server_create_buffer (struct t_irc_server *server); -int irc_server_fingerprint_search_algo_with_size (int size); char *irc_server_fingerprint_str_sizes (); extern int irc_server_connect (struct t_irc_server *server); extern void irc_server_auto_connect (int auto_connect); |