diff options
Diffstat (limited to 'vchat-client.c')
| -rwxr-xr-x | vchat-client.c | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/vchat-client.c b/vchat-client.c index f5cd516..a2e298c 100755 --- a/vchat-client.c +++ b/vchat-client.c | |||
| @@ -32,7 +32,7 @@ | |||
| 32 | #include "vchat-user.h" | 32 | #include "vchat-user.h" |
| 33 | 33 | ||
| 34 | /* version of this module */ | 34 | /* version of this module */ |
| 35 | char *vchat_cl_version = "$Id$"; | 35 | const char *vchat_cl_version = "vchat-client.c $Id$"; |
| 36 | 36 | ||
| 37 | /* externally used variables */ | 37 | /* externally used variables */ |
| 38 | /* we're logged in */ | 38 | /* we're logged in */ |
| @@ -442,6 +442,17 @@ void usage( char *name) { | |||
| 442 | puts (" -n set nickname"); | 442 | puts (" -n set nickname"); |
| 443 | printf (" -f set from (default \"%s\")\n",getstroption(CF_FROM)); | 443 | printf (" -f set from (default \"%s\")\n",getstroption(CF_FROM)); |
| 444 | puts (" -h gives this help"); | 444 | puts (" -h gives this help"); |
| 445 | puts (" -v show module versions"); | ||
| 446 | } | ||
| 447 | |||
| 448 | void versions() { | ||
| 449 | puts (vchat_cl_version); | ||
| 450 | puts (vchat_ui_version); | ||
| 451 | puts (vchat_io_version); | ||
| 452 | puts (vchat_us_version); | ||
| 453 | puts (vchat_cm_version); | ||
| 454 | puts (vchat_ssl_version); | ||
| 455 | puts (vchat_ssl_version_external); | ||
| 445 | } | 456 | } |
| 446 | 457 | ||
| 447 | /* main - d'oh */ | 458 | /* main - d'oh */ |
| @@ -456,9 +467,12 @@ main (int argc, char **argv) | |||
| 456 | loadconfig (GLOBAL_CONFIG_FILE); | 467 | loadconfig (GLOBAL_CONFIG_FILE); |
| 457 | loadconfig (getstroption (CF_CONFIGFILE)); | 468 | loadconfig (getstroption (CF_CONFIGFILE)); |
| 458 | 469 | ||
| 470 | /* make SSL version used visible */ | ||
| 471 | vchat_ssl_get_version_external(); | ||
| 472 | |||
| 459 | /* parse commandline */ | 473 | /* parse commandline */ |
| 460 | while (cmdsunparsed) { | 474 | while (cmdsunparsed) { |
| 461 | pchar = getopt(argc,argv,"C:F:lzs:p:c:n:f:kKL:h"); | 475 | pchar = getopt(argc,argv,"C:F:lzs:p:c:n:f:kKL:hv"); |
| 462 | #ifdef DEBUG | 476 | #ifdef DEBUG |
| 463 | fprintf(stderr,"parse commandline: %d ('%c'): %s\n",pchar,pchar,optarg); | 477 | fprintf(stderr,"parse commandline: %d ('%c'): %s\n",pchar,pchar,optarg); |
| 464 | #endif | 478 | #endif |
| @@ -475,6 +489,7 @@ main (int argc, char **argv) | |||
| 475 | case 'n': own_nick_set(optarg); break; | 489 | case 'n': own_nick_set(optarg); break; |
| 476 | case 'f': setstroption(CF_FROM,optarg); break; | 490 | case 'f': setstroption(CF_FROM,optarg); break; |
| 477 | case 'h': usage(argv[0]); exit(0); break; | 491 | case 'h': usage(argv[0]); exit(0); break; |
| 492 | case 'v': versions(); exit(0); break; | ||
| 478 | default : usage(argv[0]); exit(1); | 493 | default : usage(argv[0]); exit(1); |
| 479 | } | 494 | } |
| 480 | } | 495 | } |
