Mercurial > dropbear
comparison common-algo.c @ 857:c19acba28590
use oldstyle comments
author | Matt Johnston <matt@ucc.asn.au> |
---|---|
date | Thu, 14 Nov 2013 22:03:30 +0800 |
parents | 7540c0822374 |
children | 89555751c489 731f624af902 |
comparison
equal
deleted
inserted
replaced
856:f56c41030c15 | 857:c19acba28590 |
---|---|
393 | 393 |
394 /* iterate and find the first match */ | 394 /* iterate and find the first match */ |
395 for (i = 0; i < clicount; i++) { | 395 for (i = 0; i < clicount; i++) { |
396 for (j = 0; j < servcount; j++) { | 396 for (j = 0; j < servcount; j++) { |
397 if (!(servnames[j] && clinames[i])) { | 397 if (!(servnames[j] && clinames[i])) { |
398 // unusable algos are NULL | 398 /* unusable algos are NULL */ |
399 continue; | 399 continue; |
400 } | 400 } |
401 if (strcmp(servnames[j], clinames[i]) == 0) { | 401 if (strcmp(servnames[j], clinames[i]) == 0) { |
402 /* set if it was a good guess */ | 402 /* set if it was a good guess */ |
403 if (goodguess && kexguess2) { | 403 if (goodguess && kexguess2) { |
456 } | 456 } |
457 } | 457 } |
458 return 0; | 458 return 0; |
459 } | 459 } |
460 | 460 |
461 #endif // DROPBEAR_NONE_CIPHER | 461 #endif /* DROPBEAR_NONE_CIPHER */ |
462 | 462 |
463 #ifdef ENABLE_USER_ALGO_LIST | 463 #ifdef ENABLE_USER_ALGO_LIST |
464 | 464 |
465 char * | 465 char * |
466 algolist_string(algo_type algos[]) | 466 algolist_string(algo_type algos[]) |
537 | 537 |
538 /* Copy one more as a blank delimiter */ | 538 /* Copy one more as a blank delimiter */ |
539 memcpy(algos, new_algos, sizeof(*new_algos) * (num_ret+1)); | 539 memcpy(algos, new_algos, sizeof(*new_algos) * (num_ret+1)); |
540 return num_ret; | 540 return num_ret; |
541 } | 541 } |
542 #endif // ENABLE_USER_ALGO_LIST | 542 #endif /* ENABLE_USER_ALGO_LIST */ |