comparison cli-kex.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 750ec4ec4cbe
children d32bcb5c557d
comparison
equal deleted inserted replaced
1458:bdd3802c8ac6 1459:06d52bcb8094
37 #include "runopts.h" 37 #include "runopts.h"
38 #include "signkey.h" 38 #include "signkey.h"
39 #include "ecc.h" 39 #include "ecc.h"
40 40
41 41
42 static void checkhostkey(unsigned char* keyblob, unsigned int keybloblen); 42 static void checkhostkey(const unsigned char* keyblob, unsigned int keybloblen);
43 #define MAX_KNOWNHOSTS_LINE 4500 43 #define MAX_KNOWNHOSTS_LINE 4500
44 44
45 void send_msg_kexdh_init() { 45 void send_msg_kexdh_init() {
46 TRACE(("send_msg_kexdh_init()")) 46 TRACE(("send_msg_kexdh_init()"))
47 47
183 send_msg_newkeys(); 183 send_msg_newkeys();
184 ses.requirenext = SSH_MSG_NEWKEYS; 184 ses.requirenext = SSH_MSG_NEWKEYS;
185 TRACE(("leave recv_msg_kexdh_init")) 185 TRACE(("leave recv_msg_kexdh_init"))
186 } 186 }
187 187
188 static void ask_to_confirm(unsigned char* keyblob, unsigned int keybloblen, 188 static void ask_to_confirm(const unsigned char* keyblob, unsigned int keybloblen,
189 const char* algoname) { 189 const char* algoname) {
190 190
191 char* fp = NULL; 191 char* fp = NULL;
192 FILE *tty = NULL; 192 FILE *tty = NULL;
193 int response = 'z'; 193 int response = 'z';
280 out: 280 out:
281 m_free(filename); 281 m_free(filename);
282 return hostsfile; 282 return hostsfile;
283 } 283 }
284 284
285 static void checkhostkey(unsigned char* keyblob, unsigned int keybloblen) { 285 static void checkhostkey(const unsigned char* keyblob, unsigned int keybloblen) {
286 286
287 FILE *hostsfile = NULL; 287 FILE *hostsfile = NULL;
288 int readonly = 0; 288 int readonly = 0;
289 unsigned int hostlen, algolen; 289 unsigned int hostlen, algolen;
290 unsigned long len; 290 unsigned long len;