Mercurial > dropbear
comparison cli-runopts.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 | 5608a5a61c2a |
comparison
equal
deleted
inserted
replaced
856:f56c41030c15 | 857:c19acba28590 |
---|---|
214 /* A flag *waves* */ | 214 /* A flag *waves* */ |
215 | 215 |
216 switch (argv[i][1]) { | 216 switch (argv[i][1]) { |
217 case 'y': /* always accept the remote hostkey */ | 217 case 'y': /* always accept the remote hostkey */ |
218 if (cli_opts.always_accept_key) { | 218 if (cli_opts.always_accept_key) { |
219 // twice means no checking at all | 219 /* twice means no checking at all */ |
220 cli_opts.no_hostkey_check = 1; | 220 cli_opts.no_hostkey_check = 1; |
221 } | 221 } |
222 cli_opts.always_accept_key = 1; | 222 cli_opts.always_accept_key = 1; |
223 break; | 223 break; |
224 case 'p': /* remoteport */ | 224 case 'p': /* remoteport */ |
479 for (iter = cli_opts.privkeys->first; iter; iter = iter->next) | 479 for (iter = cli_opts.privkeys->first; iter; iter = iter->next) |
480 { | 480 { |
481 sign_key * key = (sign_key*)iter->item; | 481 sign_key * key = (sign_key*)iter->item; |
482 len += 3 + strlen(key->filename); | 482 len += 3 + strlen(key->filename); |
483 } | 483 } |
484 len += 30; // space for -W <size>, terminator. | 484 len += 30; /* space for -W <size>, terminator. */ |
485 ret = m_malloc(len); | 485 ret = m_malloc(len); |
486 total = 0; | 486 total = 0; |
487 | 487 |
488 if (cli_opts.no_hostkey_check) | 488 if (cli_opts.no_hostkey_check) |
489 { | 489 { |
617 cli_opts.username = m_strdup(cli_opts.own_user); | 617 cli_opts.username = m_strdup(cli_opts.own_user); |
618 } | 618 } |
619 | 619 |
620 port = strchr(cli_opts.remotehost, '%'); | 620 port = strchr(cli_opts.remotehost, '%'); |
621 if (!port) { | 621 if (!port) { |
622 // legacy separator | 622 /* legacy separator */ |
623 port = strchr(cli_opts.remotehost, '/'); | 623 port = strchr(cli_opts.remotehost, '/'); |
624 } | 624 } |
625 if (port) { | 625 if (port) { |
626 *port = '\0'; | 626 *port = '\0'; |
627 cli_opts.remoteport = port+1; | 627 cli_opts.remoteport = port+1; |