mirror of https://github.com/BOINC/boinc.git
validator: output the version string even when not in project directory
svn path=/trunk/boinc/; revision=25345
This commit is contained in:
parent
7de8d05277
commit
df439c128b
|
@ -2221,3 +2221,8 @@ Bernd 27 feb 2012
|
|||
sched/
|
||||
db_purge.cpp
|
||||
|
||||
Bernd 27 feb 2012
|
||||
- validator: output the version string even when not in project directory
|
||||
|
||||
sched/
|
||||
validator.cpp
|
||||
|
|
|
@ -700,9 +700,14 @@ int main(int argc, char** argv) {
|
|||
" -h | --help Show this\n"
|
||||
" -v | --version Show version information\n";
|
||||
|
||||
if ((argc > 1) && (!strcmp(argv[1], "-h") || !strcmp(argv[1], "--help"))) {
|
||||
if (argc > 1) {
|
||||
if (is_arg(argv[1], "h") || is_arg(argv[1], "help")) {
|
||||
printf (usage, argv[0] );
|
||||
exit(0);
|
||||
} else if (is_arg(argv[1], "v") || is_arg(argv[1], "version")) {
|
||||
printf("%s\n", SVN_VERSION);
|
||||
exit(0);
|
||||
}
|
||||
}
|
||||
|
||||
check_stop_daemons();
|
||||
|
@ -735,9 +740,6 @@ int main(int argc, char** argv) {
|
|||
max_runtime = atof(argv[++i]);
|
||||
} else if (is_arg(argv[i], "no_credit")) {
|
||||
no_credit = true;
|
||||
} else if (is_arg(argv[i], "v") || is_arg(argv[i], "version")) {
|
||||
printf("%s\n", SVN_VERSION);
|
||||
exit(0);
|
||||
} else {
|
||||
fprintf(stderr,
|
||||
"Invalid option '%s'\nTry `%s --help` for more information\n",
|
||||
|
|
Loading…
Reference in New Issue