mirror of
https://github.com/MariaDB/server.git
synced 2025-01-23 15:24:16 +01:00
Get rid of random seeds. Addresses #162.
git-svn-id: file:///svn/tokudb@1067 c7de825b-a66e-492c-adef-691d508d4ae1
This commit is contained in:
parent
b5ca65fe2e
commit
fab0a6aa16
1 changed files with 2 additions and 8 deletions
|
@ -330,13 +330,12 @@ static void activity (void) {
|
|||
|
||||
|
||||
static void usage (const char *argv1) {
|
||||
fprintf(stderr, "Usage:\n %s [ --DB-CREATE | --more ] seed ", argv1);
|
||||
fprintf(stderr, "Usage:\n %s [ --more ]\n", argv1);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
int main (int argc, const char *argv[]) {
|
||||
const char *progname=argv[0];
|
||||
int useseed=1;
|
||||
|
||||
memset(&nc_key, 0, sizeof(nc_key));
|
||||
memset(&nc_data, 0, sizeof(nc_data));
|
||||
|
@ -353,12 +352,7 @@ int main (int argc, const char *argv[]) {
|
|||
if (strcmp(argv[0], "--more")==0) {
|
||||
mode = MODE_MORE;
|
||||
} else {
|
||||
errno=0;
|
||||
char *endptr;
|
||||
useseed = strtoul(argv[0], &endptr, 10);
|
||||
if (errno!=0 || *endptr!=0 || endptr==argv[0]) {
|
||||
usage(progname);
|
||||
}
|
||||
usage(progname);
|
||||
}
|
||||
argc--; argv++;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue