Mercurial > dropbear
diff common-algo.c @ 1459:06d52bcb8094
Pointer parameter could be declared as pointing to const
author | Francois Perrad <francois.perrad@gadz.org> |
---|---|
date | Sat, 19 Aug 2017 17:16:13 +0200 |
parents | 2c9dac2d6707 |
children | 533e070b3126 |
line wrap: on
line diff
--- a/common-algo.c Sat Aug 12 20:51:58 2017 +0200 +++ b/common-algo.c Sat Aug 19 17:16:13 2017 +0200 @@ -314,7 +314,7 @@ * against. * Returns DROPBEAR_SUCCESS if we have a match for algo, DROPBEAR_FAILURE * otherwise */ -int have_algo(char* algo, size_t algolen, algo_type algos[]) { +int have_algo(const char* algo, size_t algolen, const algo_type algos[]) { int i; @@ -329,7 +329,7 @@ } /* Output a comma separated list of algorithms to a buffer */ -void buf_put_algolist(buffer * buf, algo_type localalgos[]) { +void buf_put_algolist(buffer * buf, const algo_type localalgos[]) { unsigned int i, len; unsigned int donefirst = 0; @@ -501,7 +501,7 @@ #if DROPBEAR_USER_ALGO_LIST char * -algolist_string(algo_type algos[]) +algolist_string(const algo_type algos[]) { char *ret_list; buffer *b = buf_new(200);