mirror of
https://github.com/MariaDB/server.git
synced 2025-01-23 15:24:16 +01:00
18 lines
362 B
C
18 lines
362 B
C
|
int verbose=0;
|
||
|
|
||
|
void default_parse_args (int argc, const char *argv[]) {
|
||
|
const char *progname=argv[0];
|
||
|
argc--; argv++;
|
||
|
while (argc>0) {
|
||
|
if (strcmp(argv[0],"-v")==0) {
|
||
|
verbose=1;
|
||
|
} else if (strcmp(argv[0],"-q")==0) {
|
||
|
verbose=0;
|
||
|
} else {
|
||
|
fprintf(stderr, "Usage:\n %s [-v] [-q]\n", progname);
|
||
|
exit(1);
|
||
|
}
|
||
|
argc--; argv++;
|
||
|
}
|
||
|
}
|