Commit cf034621 authored by Yoni Fogel's avatar Yoni Fogel

Addresses #1510 Change argv to support getopt, remove const for ease of use.

git-svn-id: file:///svn/toku/tokudb@11400 c7de825b-a66e-492c-adef-691d508d4ae1
parent f47dce49
......@@ -108,7 +108,7 @@ test_shutdown (void) {
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
setup();
test_abort_abort();
......
......@@ -107,7 +107,7 @@ test_shutdown (void) {
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
setup();
test_abort_commit();
......
......@@ -103,7 +103,7 @@ test_shutdown (void) {
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
setup();
test_commit_abort();
......
......@@ -103,7 +103,7 @@ test_shutdown (void) {
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
setup();
test_commit_commit();
......
......@@ -89,7 +89,7 @@ do_1381 (void) {
}
int
test_main (int argc, const char *argv[])
test_main (int argc, char *argv[])
{
parse_args(argc, argv);
do_1381();
......
......@@ -66,7 +66,7 @@ do_627 (void) {
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
do_627();
return 0;
......
......@@ -48,7 +48,7 @@ checkpoint1 (void)
}
int
test_main (int argc, const char *argv[])
test_main (int argc, char *argv[])
{
parse_args(argc, argv);
checkpoint1();
......
......@@ -152,7 +152,7 @@ void checkpoint_callback_2(void * extra) {
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
u_int32_t n;
int snap;
......
......@@ -97,7 +97,7 @@ doit (BOOL committed_provdels) {
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
setup();
......
......@@ -61,7 +61,7 @@ doit (void) {
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
test_setup();
......
......@@ -182,7 +182,7 @@ do_writes_that_fail (void) {
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
do_writes_that_fail();
return 0;
......
......@@ -16,7 +16,7 @@ void *startb(void* ignore __attribute__((__unused__))) {
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
pthread_t a,b;
{ int x_l = pthread_create(&a, NULL, starta, NULL); assert(x_l==0); }
......
......@@ -87,7 +87,7 @@ void *startb(void* ignore __attribute__((__unused__))) {
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
pthread_t a,b;
initialize();
......
......@@ -87,7 +87,7 @@ void *startb(void* ignore __attribute__((__unused__))) {
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
pthread_t a,b;
initialize();
......
......@@ -67,7 +67,7 @@ static void test (void) {
}
int
test_main (int argc , const char *argv[]) {
test_main (int argc , char *argv[]) {
parse_args(argc, argv);
test();
return 0;
......
......@@ -90,7 +90,7 @@ static void test (void) {
}
int
test_main (int argc , const char *argv[]) {
test_main (int argc , char *argv[]) {
parse_args(argc, argv);
test();
return 0;
......
......@@ -76,7 +76,7 @@ static void test (void) {
}
int
test_main (int argc , const char *argv[]) {
test_main (int argc , char *argv[]) {
parse_args(argc, argv);
test();
return 0;
......
......@@ -79,7 +79,7 @@ static void test (void) {
}
int
test_main (int argc , const char *argv[]) {
test_main (int argc , char *argv[]) {
parse_args(argc, argv);
test();
return 0;
......
......@@ -74,7 +74,7 @@ doit (void) {
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
test_setup();
......
......@@ -112,7 +112,7 @@ test_shutdown (void) {
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
test_setup();
test_commit_commit();
......
......@@ -87,7 +87,7 @@ static void root_fifo_1(int n) {
r = env->close(env, 0); assert(r == 0); env = null_env;
}
int test_main(int argc, const char *argv[]) {
int test_main(int argc, char *argv[]) {
int i;
int n = -1;
......
......@@ -87,7 +87,7 @@ static void root_fifo_1(int n) {
r = env->close(env, 0); assert(r == 0); env = null_env;
}
int test_main(int argc, const char *argv[]) {
int test_main(int argc, char *argv[]) {
int i;
int n = -1;
......
......@@ -127,7 +127,7 @@ static void root_fifo_31(int n) {
r = env->close(env, 0); assert(r == 0); env = null_env;
}
int test_main(int argc, const char *argv[]) {
int test_main(int argc, char *argv[]) {
int i;
int n = -1;
......
......@@ -127,7 +127,7 @@ static void root_fifo_32(int n) {
r = env->close(env, 0); assert(r == 0); env = null_env;
}
int test_main(int argc, const char *argv[]) {
int test_main(int argc, char *argv[]) {
int i;
int n = -1;
......
......@@ -132,7 +132,7 @@ static void root_fifo_41(int n, int ntxn, BOOL do_populate) {
r = env->close(env, 0); assert(r == 0); env = null_env;
}
int test_main(int argc, const char *argv[]) {
int test_main(int argc, char *argv[]) {
int i;
int n = -1;
int ntxn = -1;
......
......@@ -65,7 +65,7 @@ test_stat64 (unsigned int N)
}
int
test_main (int argc, const char *argv[])
test_main (int argc, char *argv[])
{
parse_args(argc, argv);
test_stat64(40000);
......
......@@ -52,7 +52,7 @@ static void test (void) {
}
int
test_main (int argc __attribute__((__unused__)), const char *argv[] __attribute__((__unused__))) {
test_main (int argc __attribute__((__unused__)), char *argv[] __attribute__((__unused__))) {
test();
return 0;
}
......
......@@ -69,7 +69,7 @@ static void test (void) {
}
int
test_main (int argc __attribute__((__unused__)), const char *argv[] __attribute__((__unused__))) {
test_main (int argc __attribute__((__unused__)), char *argv[] __attribute__((__unused__))) {
test();
return 0;
}
......
......@@ -82,7 +82,7 @@ static void test (void) {
}
int
test_main (int argc __attribute__((__unused__)), const char *argv[] __attribute__((__unused__))) {
test_main (int argc __attribute__((__unused__)), char *argv[] __attribute__((__unused__))) {
test();
return 0;
}
......
......@@ -42,7 +42,7 @@ int verbose=0;
#endif
static __attribute__((__unused__)) void
parse_args (int argc, const char *argv[]) {
parse_args (int argc, char *argv[]) {
const char *argv0=argv[0];
while (argc>1) {
int resultcode=0;
......@@ -139,9 +139,9 @@ typedef enum __toku_bool { FALSE=0, TRUE=1} BOOL;
#endif
#include <memory.h>
int test_main (int argc, const char *argv[]);
int test_main (int argc, char *argv[]);
int
main(int argc, const char *argv[]) {
main(int argc, char *argv[]) {
int r;
#if IS_TDB && (defined(_WIN32) || defined(_WIN64))
toku_ydb_init();
......
......@@ -69,7 +69,7 @@ do_1324 (int moreflags)
}
int
test_main (int argc, const char *argv[])
test_main (int argc, char *argv[])
{
parse_args(argc, argv);
do_1324(DB_INIT_LOG);
......
......@@ -97,7 +97,7 @@ do_insert_delete_fifo (void)
}
int
test_main (int argc, const char *argv[])
test_main (int argc, char *argv[])
{
parse_args(argc, argv);
do_insert_delete_fifo();
......
......@@ -61,7 +61,7 @@ four_billion_subtransactions (int do_something_in_children, int use_big_incremen
}
int
test_main (int argc, const char *argv[])
test_main (int argc, char *argv[])
{
parse_args(argc, argv);
four_billion_subtransactions(0, 0);
......
......@@ -118,7 +118,7 @@ run (int choice) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
system("rm -rf " ENVDIR);
......
......@@ -50,7 +50,7 @@ run (void) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
system("rm -rf " ENVDIR);
......
......@@ -51,7 +51,7 @@ run (void) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
system("rm -rf " ENVDIR);
......
......@@ -108,7 +108,7 @@ run (int choice) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
system("rm -rf " ENVDIR);
......
......@@ -105,7 +105,7 @@ run (int choice) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
system("rm -rf " ENVDIR);
......
......@@ -137,7 +137,7 @@ test_789(void) {
}
int
test_main(int UU(argc), const char UU(*argv[])) {
test_main(int UU(argc), char UU(*argv[])) {
test_789();
return 0;
}
......@@ -79,7 +79,7 @@ testit (const int klen, const int vlen, const int n, const int lastvlen) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
const int meg = 1024*1024;
const int headeroverhead = 12*4;
......
......@@ -157,7 +157,7 @@ test_db_put_aborts (void) {
}
int
test_main (int UU(argc), const char UU(*argv[])) {
test_main (int UU(argc), char UU(*argv[])) {
test_db_open_aborts();
test_db_put_aborts();
return 0;
......
......@@ -111,7 +111,7 @@ do_test_abort2 (void) {
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
do_test_abort2();
return 0;
......
......@@ -161,7 +161,7 @@ test_abort3 (void) {
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
test_abort3();
return 0;
......
......@@ -156,7 +156,7 @@ runtests(u_int32_t dup_flags) {
}
int
test_main (int UU(argc), const char UU(*argv[])) {
test_main (int UU(argc), char UU(*argv[])) {
runtests(0);
runtests(DB_DUPSORT|DB_DUP);
return 0;
......
......@@ -196,7 +196,7 @@ runtests(u_int32_t dup_flags, int abort_type) {
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
int abort_type;
for (abort_type = 0; abort_type<3; abort_type++) {
......
......@@ -124,7 +124,7 @@ do_abort_delete_first_or_last(int N,
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
int f;
for (f=0; f<2; f++) {
......
......@@ -8,7 +8,7 @@
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
DB_ENV *env;
DB *db;
......
......@@ -7,7 +7,7 @@
#include <memory.h>
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
DB_ENV *env;
DB *db;
......
......@@ -6,7 +6,7 @@
#include <sys/stat.h>
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
DB_ENV *env;
DB *db, *db2;
......
......@@ -79,7 +79,7 @@ test_cachesize (void) {
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
test_cachesize();
......
......@@ -78,7 +78,7 @@ test_cursor (void) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
......
......@@ -90,7 +90,7 @@ test (void) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
......
......@@ -177,7 +177,7 @@ static void run_test(u_int32_t dup_flags) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
......
......@@ -113,7 +113,7 @@ test_reopen (void) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
system("rm -rf " ENVDIR);
......
......@@ -154,7 +154,7 @@ test_cursor_delete_dupsort (void) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
test_cursor_delete(0);
......
......@@ -60,7 +60,7 @@ test_cursor_delete2 (void) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
......
......@@ -62,7 +62,7 @@ test_cursor_delete2 (void) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
......
......@@ -68,7 +68,7 @@ cursor_range_with_delete (u_int32_t flag) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
setup_db("next.db");
insert();
......
......@@ -41,7 +41,7 @@ test_cursor_flags (int cursor_flags, int expectr) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
......
......@@ -89,7 +89,7 @@ test_cursor_nonleaf_expand (int n, int reverse) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
int i;
......
......@@ -171,7 +171,7 @@ test (u_int32_t dup_flags) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
test(0);
test(DB_DUP | DB_DUPSORT);
......
......@@ -77,7 +77,7 @@ test_cursor_sticky (int n, int dup_mode) {
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
int i;
// setvbuf(stdout, NULL, _IONBF, 0);
......
......@@ -14,7 +14,7 @@
// ENVDIR is defined in the Makefile
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
DB_ENV * const null_env = 0;
DB *db;
......
......@@ -16,7 +16,7 @@ DB_ENV *env;
DB *db;
int
test_main (int UU(argc), const char UU(*argv[])) {
test_main (int UU(argc), char UU(*argv[])) {
int r;
system("rm -rf " ENVDIR);
r=toku_os_mkdir(ENVDIR, S_IRWXU+S_IRWXG+S_IRWXO); assert(r==0);
......
......@@ -17,7 +17,7 @@ DB *db;
DB_TXN* null_txn = NULL;
int
test_main (int UU(argc), const char UU(*argv[])) {
test_main (int UU(argc), char UU(*argv[])) {
int r;
system("rm -rf " ENVDIR);
r=toku_os_mkdir(ENVDIR, S_IRWXU+S_IRWXG+S_IRWXO); CKERR(r);
......
......@@ -57,7 +57,7 @@ close_dbs (void) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
int i;
int r;
......
......@@ -162,7 +162,7 @@ test_db_delboth (int n, int dup_mode) {
#endif //USE_TDB
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
......
......@@ -135,7 +135,7 @@ test_db_get_datasize0 (void) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
test_db_get_datasize0();
......
......@@ -208,7 +208,7 @@ runtest(void) {
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
for (abort_type = 0; abort_type < 3; abort_type++) {
......
......@@ -8,7 +8,7 @@
#include <db.h>
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
DB_ENV *dbenv;
int r;
......
......@@ -68,7 +68,7 @@ reinit_config (int set_home, int set_DB_ENVIRON, int set_DB_HOME) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
DB_ENV *env;
DB_TXN * const null_txn = 0;
......
......@@ -23,7 +23,7 @@
// ENVDIR is defined in the Makefile
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
DB_ENV *dbenv;
int r;
......
......@@ -14,7 +14,7 @@
// ENVDIR is defined in the Makefile
int
test_main(int argc, const char** argv) {
test_main(int argc, char** argv) {
DB_ENV *dbenv;
int r;
if (argc == 2 && !strcmp(argv[1], "-v")) verbose = 1;
......
......@@ -13,7 +13,7 @@
// ENVDIR is defined in the Makefile
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
DB_ENV *dbenv;
int r;
......
......@@ -13,7 +13,7 @@
// ENVDIR is defined in the Makefile
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
DB_ENV *dbenv;
int r;
......
......@@ -14,7 +14,7 @@
// ENVDIR is defined in the Makefile
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
DB_ENV *dbenv;
int r;
......
......@@ -14,7 +14,7 @@
// ENVDIR is defined in the Makefile
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
DB_ENV *dbenv;
int r;
......
......@@ -16,7 +16,7 @@ DB_ENV *env;
DB *db;
int
test_main (int UU(argc), const char UU(*argv[])) {
test_main (int UU(argc), char UU(*argv[])) {
int r;
r=system("rm -rf " ENVDIR); assert(r==0);
r=toku_os_mkdir(ENVDIR, S_IRWXU+S_IRWXG+S_IRWXO); assert(r==0);
......
......@@ -129,7 +129,7 @@ GET_TEST get_tests[] = {
const int num_get = sizeof(get_tests) / sizeof(get_tests[0]);
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
int i;
parse_args(argc, argv);
......
......@@ -90,7 +90,7 @@ runtest(void) {
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
runtest();
......
......@@ -10,7 +10,7 @@
int
test_main (int UU(argc), const char UU(*argv[])) {
test_main (int UU(argc), char UU(*argv[])) {
DB *db;
int r;
r = db_create(&db, 0, 0);
......
......@@ -16,7 +16,7 @@ DB_ENV *env;
DB *db;
int
test_main (int UU(argc), const char UU(*argv[])) {
test_main (int UU(argc), char UU(*argv[])) {
int r;
system("rm -rf " ENVDIR);
r=toku_os_mkdir(ENVDIR, S_IRWXU+S_IRWXG+S_IRWXO); assert(r==0);
......
......@@ -35,7 +35,7 @@ void test_db_remove (void) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
test_db_remove();
......
......@@ -19,7 +19,7 @@ DBT key;
DBT data;
int
test_main (int UU(argc), const char UU(*argv[])) {
test_main (int UU(argc), char UU(*argv[])) {
int r;
system("rm -rf " ENVDIR);
r=toku_os_mkdir(ENVDIR, S_IRWXU+S_IRWXG+S_IRWXO); assert(r==0);
......
......@@ -19,7 +19,7 @@ DBT key;
DBT data;
int
test_main (int UU(argc), const char UU(*argv[])) {
test_main (int UU(argc), char UU(*argv[])) {
int r;
system("rm -rf " ENVDIR);
r=toku_os_mkdir(ENVDIR, S_IRWXU+S_IRWXG+S_IRWXO); assert(r==0);
......
......@@ -34,7 +34,7 @@ test_db_set_flags (int flags, int expectr, int flags2, int expectr2) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
......
......@@ -13,7 +13,7 @@
// ENVDIR is defined in the Makefile
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
DB_ENV * env = 0;
DB *db;
......
......@@ -13,7 +13,7 @@
// ENVDIR is defined in the Makefile
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
DB_ENV * env = 0;
DB *db;
......
......@@ -424,7 +424,7 @@ test (u_int32_t dup_flags) {
int
test_main(int argc, const char* argv[]) {
test_main(int argc, char* argv[]) {
parse_args(argc, argv);
if (!IS_TDB) {
if (verbose) {
......
......@@ -682,7 +682,7 @@ test (u_int32_t dup_flags) {
int
test_main(int argc, const char* argv[]) {
test_main(int argc, char* argv[]) {
parse_args(argc, argv);
if (!IS_TDB) {
if (verbose) {
......
......@@ -218,7 +218,7 @@ test (u_int32_t dup_flags) {
int
test_main(int argc, const char* argv[]) {
test_main(int argc, char* argv[]) {
parse_args(argc, argv);
test(0);
test(DB_DUP | DB_DUPSORT);
......
......@@ -7,7 +7,7 @@
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
const char *v;
int major, minor, patch;
parse_args(argc, argv);
......
......@@ -47,7 +47,7 @@ delete_db(char *name) {
}
int
test_main (int UU(argc), const char UU(*argv[])) {
test_main (int UU(argc), char UU(*argv[])) {
int r;
r=system("rm -rf " ENVDIR);
CKERR(r);
......
......@@ -704,7 +704,7 @@ test_i0i1ci0_search (int n, int dup_mode) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
int i;
int r;
......
......@@ -221,7 +221,7 @@ test_put_00_01_01 (int dup_mode, u_int32_t put_flags) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
int yes_overwrite=0;
if (IS_TDB)
......
......@@ -69,7 +69,7 @@ test_dup_flags (u_int32_t dup_flags) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
......
......@@ -251,7 +251,7 @@ test_nonleaf_insert (int n, int dup_mode) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
int i;
parse_args(argc, argv);
......
......@@ -119,7 +119,7 @@ test_dup_next (int n, int dup_mode) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
int i;
for (i = 1; i < argc; i++) {
const char *arg = argv[i];
......
......@@ -321,7 +321,7 @@ test_reverse_search (int n, int dup_mode) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
int i;
parse_args(argc, argv);
......
......@@ -101,7 +101,7 @@ test_dupsort_del (void) {
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
test_dupsort_del();
return 0;
......
......@@ -108,7 +108,7 @@ test_abort3 (void) {
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
test_abort3();
return 0;
......
......@@ -97,7 +97,7 @@ test_dupsort_delete (int n) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
int i;
parse_args(argc, argv);
......
......@@ -119,7 +119,7 @@ test_dupsort_get (int n, int dup_mode) {
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
int i;
parse_args(argc, argv);
......
......@@ -144,7 +144,7 @@ test_icdi_search (int n, int dup_mode) {
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
int i;
parse_args(argc, argv);
......
......@@ -150,7 +150,7 @@ test_icdi_search (int n, int dup_mode) {
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
int i;
parse_args(argc, argv);
......
......@@ -145,7 +145,7 @@ test_icdi_search (int n, int dup_mode) {
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
int i;
parse_args(argc, argv);
......
......@@ -153,7 +153,7 @@ test_icdi_search (int n, int dup_mode) {
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
int i;
parse_args(argc, argv);
......
......@@ -14,7 +14,7 @@
// ENVDIR is defined in the Makefile
int
test_main (int argc __attribute__((__unused__)), const char *argv[] __attribute__((__unused__))) {
test_main (int argc __attribute__((__unused__)), char *argv[] __attribute__((__unused__))) {
DB_ENV *env;
int r;
system("rm -rf " ENVDIR);
......
......@@ -10,7 +10,7 @@
int
test_main (int UU(argc), const char UU(*argv[])) {
test_main (int UU(argc), char UU(*argv[])) {
DB_ENV *env;
DB *db;
int r;
......
......@@ -31,7 +31,7 @@ test_env_open_flags (int env_open_flags, int expectr) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
......
......@@ -16,7 +16,7 @@ handle_error (const DB_ENV *UU(dbenv), const char *errpfx, const char *UU(msg))
n_handle_error++;
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
#if defined(OSX)
......
......@@ -13,7 +13,7 @@ f (void *arg) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
toku_pthread_t t;
int r = toku_pthread_create(&t, 0, f, 0); assert(r == 0);
......
......@@ -109,7 +109,7 @@ static void test_get_both(int n, int dup_mode, int op) {
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
unsigned long doi=0;
int i;
char flags = 0;
......
......@@ -33,7 +33,7 @@ test_get (int dup_mode) {
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
system("rm -rf " ENVDIR);
toku_os_mkdir(ENVDIR, S_IRWXU+S_IRWXG+S_IRWXO);
......
......@@ -99,7 +99,7 @@ printtdiff (char *str) {
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
progname=argv[0];
parse_args(argc, argv);
......
......@@ -94,7 +94,7 @@ printtdiff (char *str) {
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
system("rm -rf " ENVDIR);
......
......@@ -250,7 +250,7 @@ test(u_int32_t dup_flags) {
}
int
test_main(int argc, const char* argv[]) {
test_main(int argc, char* argv[]) {
parse_args(argc, argv);
test(0);
test(DB_DUP | DB_DUPSORT);
......
......@@ -109,7 +109,7 @@ test_hsoc (int pagesize, int dup_mode) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
test_hsoc(4096, DB_DUP + DB_DUPSORT);
......
......@@ -65,7 +65,7 @@ test_insert_delete_insert (int dup_mode) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
......
......@@ -44,7 +44,7 @@ test_insert (int n, int dup_mode) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
system("rm -rf " ENVDIR);
......
......@@ -126,7 +126,7 @@ test_data_size_limit (int dup_mode) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
int i;
for (i = 1; i < argc; i++) {
const char *arg = argv[i];
......
......@@ -15,7 +15,7 @@
DB_ENV *env;
int
test_main (int UU(argc), const char UU(*argv[])) {
test_main (int UU(argc), char UU(*argv[])) {
int r;
system("rm -rf " ENVDIR);
r=toku_os_mkdir(ENVDIR, S_IRWXU+S_IRWXG+S_IRWXO); assert(r==0);
......
......@@ -20,7 +20,7 @@ DB *db;
DB_TXN *tid;
int
test_main (int UU(argc), const char UU(*argv[])) {
test_main (int UU(argc), char UU(*argv[])) {
int r;
system("rm -rf " ENVDIR);
r=toku_os_mkdir(ENVDIR, S_IRWXU+S_IRWXG+S_IRWXO); assert(r==0);
......
......@@ -101,7 +101,7 @@ static void make_db (void) {
}
int
test_main (int argc __attribute__((__unused__)), const char *argv[] __attribute__((__unused__))) {
test_main (int argc __attribute__((__unused__)), char *argv[] __attribute__((__unused__))) {
make_db();
return 0;
}
......@@ -21,7 +21,7 @@ DB *db;
DB_TXN *tid;
int
test_main (int UU(argc), const char UU(*argv[])) {
test_main (int UU(argc), char UU(*argv[])) {
int r;
system("rm -rf " ENVDIR);
r=toku_os_mkdir(ENVDIR, S_IRWXU+S_IRWXG+S_IRWXO); assert(r==0);
......
......@@ -34,7 +34,7 @@ static void make_db (void) {
}
int
test_main (int argc __attribute__((__unused__)), const char *argv[] __attribute__((__unused__))) {
test_main (int argc __attribute__((__unused__)), char *argv[] __attribute__((__unused__))) {
make_db();
return 0;
}
......@@ -34,7 +34,7 @@ static void make_db (void) {
}
int
test_main (int argc __attribute__((__unused__)), const char *argv[] __attribute__((__unused__))) {
test_main (int argc __attribute__((__unused__)), char *argv[] __attribute__((__unused__))) {
make_db();
return 0;
}
......@@ -44,7 +44,7 @@ static void make_db (void) {
}
int
test_main (int argc __attribute__((__unused__)), const char *argv[] __attribute__((__unused__))) {
test_main (int argc __attribute__((__unused__)), char *argv[] __attribute__((__unused__))) {
make_db();
return 0;
}
......@@ -54,7 +54,7 @@ static void make_db (void) {
}
int
test_main (int argc __attribute__((__unused__)), const char *argv[] __attribute__((__unused__))) {
test_main (int argc __attribute__((__unused__)), char *argv[] __attribute__((__unused__))) {
make_db();
return 0;
}
......@@ -50,7 +50,7 @@ static void make_db (void) {
}
int
test_main (int argc __attribute__((__unused__)), const char *argv[] __attribute__((__unused__))) {
test_main (int argc __attribute__((__unused__)), char *argv[] __attribute__((__unused__))) {
make_db();
return 0;
}
......@@ -62,7 +62,7 @@ static void make_db (void) {
}
int
test_main (int argc __attribute__((__unused__)), const char *argv[] __attribute__((__unused__))) {
test_main (int argc __attribute__((__unused__)), char *argv[] __attribute__((__unused__))) {
make_db();
return 0;
}
......@@ -69,7 +69,7 @@ static void make_db (void) {
}
int
test_main (int argc __attribute__((__unused__)), const char *argv[] __attribute__((__unused__))) {
test_main (int argc __attribute__((__unused__)), char *argv[] __attribute__((__unused__))) {
make_db();
return 0;
}
......@@ -81,7 +81,7 @@ static void make_db (void) {
}
int
test_main (int argc __attribute__((__unused__)), const char *argv[] __attribute__((__unused__))) {
test_main (int argc __attribute__((__unused__)), char *argv[] __attribute__((__unused__))) {
make_db();
return 0;
}
......@@ -109,7 +109,7 @@ static void make_db (void) {
}
int
test_main (int argc __attribute__((__unused__)), const char *argv[] __attribute__((__unused__))) {
test_main (int argc __attribute__((__unused__)), char *argv[] __attribute__((__unused__))) {
make_db();
return 0;
}
......@@ -121,7 +121,7 @@ static void make_db (void) {
}
int
test_main (int argc __attribute__((__unused__)), const char *argv[] __attribute__((__unused__))) {
test_main (int argc __attribute__((__unused__)), char *argv[] __attribute__((__unused__))) {
make_db();
return 0;
}
......@@ -296,7 +296,7 @@ static void make_db (void) {
}
int
test_main (int argc __attribute__((__unused__)), const char *argv[] __attribute__((__unused__))) {
test_main (int argc __attribute__((__unused__)), char *argv[] __attribute__((__unused__))) {
make_db();
return 0;
}
......@@ -79,7 +79,7 @@ static void make_db (void) {
}
int
test_main (int argc __attribute__((__unused__)), const char *argv[] __attribute__((__unused__))) {
test_main (int argc __attribute__((__unused__)), char *argv[] __attribute__((__unused__))) {
make_db();
return 0;
}
......@@ -93,7 +93,7 @@ static void make_db (void) {
}
int
test_main (int argc __attribute__((__unused__)), const char *argv[] __attribute__((__unused__))) {
test_main (int argc __attribute__((__unused__)), char *argv[] __attribute__((__unused__))) {
make_db();
return 0;
}
......@@ -93,7 +93,7 @@ static void make_db (void) {
}
int
test_main (int argc __attribute__((__unused__)), const char *argv[] __attribute__((__unused__))) {
test_main (int argc __attribute__((__unused__)), char *argv[] __attribute__((__unused__))) {
make_db();
return 0;
}
......@@ -26,7 +26,7 @@ grep_for_in_logs (const char *str) {
}
int
test_main (int UU(argc), const char UU(*argv[])) {
test_main (int UU(argc), char UU(*argv[])) {
int r;
DB_ENV *env;
DB *db;
......
......@@ -101,7 +101,7 @@ test_logmax (int logmax) {
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
test_logmax(1<<20);
test_logmax(-1);
......
......@@ -45,7 +45,7 @@ seqinsert (int n, float p) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
srandom(time(0));
int i;
for (i=1; i<argc; i++) {
......
......@@ -142,7 +142,7 @@ test_nested (void) {
}
int
test_main (int argc, const char *argv[]) {
test_main (int argc, char *argv[]) {
parse_args(argc, argv);
test_nested();
return 0;
......
......@@ -153,7 +153,7 @@ test_icdi_search (int n, int dup_mode) {
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
int i;
parse_args(argc, argv);
......
......@@ -82,7 +82,7 @@ test_rand_insert (int n, int dup_mode) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
int i;
......
......@@ -138,7 +138,7 @@ test_reverse_compare (int n, int dup_flags) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
int i;
......
......@@ -92,7 +92,7 @@ test1 (void)
}
int
test_main (int argc __attribute__((__unused__)), const char *argv[] __attribute__((__unused__)))
test_main (int argc __attribute__((__unused__)), char *argv[] __attribute__((__unused__)))
{
test1();
return 0;
......
......@@ -117,7 +117,7 @@ static void make_db (int n_locks) {
}
int
test_main (int argc __attribute__((__unused__)), const char *argv[] __attribute__((__unused__))) {
test_main (int argc __attribute__((__unused__)), char *argv[] __attribute__((__unused__))) {
make_db(-1);
make_db(100);
if (0) {
......
......@@ -74,7 +74,7 @@ test_db_thread (void) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
system("rm -rf " ENVDIR);
toku_os_mkdir(ENVDIR, S_IRWXU+S_IRWXG+S_IRWXO);
......
......@@ -54,7 +54,7 @@ usage (void) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
const char *dbfile = "test.db";
const char *dbname = "main";
int nthreads = 2;
......
......@@ -52,7 +52,7 @@ usage (void) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
const char *dbfile = "test.db";
const char *dbname = "main";
int all_on_threads = 0;
......
......@@ -91,7 +91,7 @@ test_truncate (int n) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
int nodesize = 1024*1024;
int leafentry = 25;
......
......@@ -100,7 +100,7 @@ test_truncate_subdb (int n) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
int nodesize = 1024*1024;
int leafentry = 25;
......
......@@ -108,7 +108,7 @@ test_truncate_txn_abort (int n) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
int nodesize = 1024*1024;
int leafentry = 25;
......
......@@ -108,7 +108,7 @@ test_truncate_txn_commit (int n) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
int nodesize = 1024*1024;
int leafentry = 25;
......
......@@ -116,7 +116,7 @@ test_truncate_txn_commit2 (int n) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
int nodesize = 1024*1024;
int leafentry = 25;
......
......@@ -116,7 +116,7 @@ test_truncate_txn_commit2 (int n) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
int nodesize = 1024*1024;
int leafentry = 25;
......
......@@ -126,7 +126,7 @@ test_truncate_with_cursors (int n) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
int nodesize = 1024*1024;
int leafentry = 25;
......
......@@ -63,7 +63,7 @@ test_txn_abort (int n) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
int i;
for (i = 1; i < argc; i++) {
const char *arg = argv[i];
......
......@@ -80,7 +80,7 @@ test_txn_abort (int n) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
int i;
for (i = 1; i < argc; i++) {
const char *arg = argv[i];
......
......@@ -108,7 +108,7 @@ test_txn_abort (int n, int which_guys_to_abort) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
int i,j;
for (i = 1; i < argc; i++) {
const char *arg = argv[i];
......
......@@ -53,7 +53,7 @@ test_abort_create (void) {
}
int
test_main(int UU(argc), const char UU(*argv[])) {
test_main(int UU(argc), char UU(*argv[])) {
test_abort_create();
return 0;
}
......@@ -61,7 +61,7 @@ test_abort_close (void) {
}
int
test_main(int UU(argc), const char UU(*argv[])) {
test_main(int UU(argc), char UU(*argv[])) {
test_abort_close();
return 0;
}
......@@ -68,7 +68,7 @@ test_abort_close (void) {
}
int
test_main(int UU(argc), const char UU(*argv[])) {
test_main(int UU(argc), char UU(*argv[])) {
test_abort_close();
return 0;
}
......@@ -8,7 +8,7 @@
int
test_main(int UU(argc), const char UU(*argv[])) {
test_main(int UU(argc), char UU(*argv[])) {
int r;
DB_ENV *env;
......
......@@ -73,7 +73,7 @@ test_txn_close_open_commit (void) {
}
int
test_main(int UU(argc), const char UU(*argv[])) {
test_main(int UU(argc), char UU(*argv[])) {
test_txn_close_open_commit();
return 0;
}
......@@ -61,7 +61,7 @@ test_abort_close (void) {
}
int
test_main(int UU(argc), const char UU(*argv[])) {
test_main(int UU(argc), char UU(*argv[])) {
test_abort_close();
return 0;
}
......@@ -200,7 +200,7 @@ test_txn_cursor_last_2 (int nrows) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
......
......@@ -81,7 +81,7 @@ test_txn_nested(int do_commit) {
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
......
......@@ -76,7 +76,7 @@ test_txn_abort (void) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
test_txn_abort();
return 0;
......
......@@ -82,7 +82,7 @@ test_txn_abort (void) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
test_txn_abort();
return 0;
......
......@@ -108,7 +108,7 @@ test_txn_abort (int insert, int secondnum) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
test_txn_abort(1, 0);
test_txn_abort(0, 0);
......
......@@ -88,7 +88,7 @@ test_txn_recover3 (int nrows) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
......
......@@ -80,7 +80,7 @@ test_cursor_nonleaf_expand (int n, int reverse) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
system("rm -rf " ENVDIR);
......
......@@ -64,7 +64,7 @@ test_autotxn (u_int32_t env_flags, u_int32_t db_flags) {
}
int
test_main (int argc __attribute__((__unused__)), const char *argv[] __attribute__((__unused__))) {
test_main (int argc __attribute__((__unused__)), char *argv[] __attribute__((__unused__))) {
test_autotxn(DB_AUTO_COMMIT, DB_AUTO_COMMIT);
test_autotxn(0, DB_AUTO_COMMIT);
test_autotxn(DB_AUTO_COMMIT, 0);
......
......@@ -137,7 +137,7 @@ test_insert_zero_length_keys (int n, int dup_mode, const char *dbname) {
}
int
test_main(int argc, const char *argv[]) {
test_main(int argc, char *argv[]) {
parse_args(argc, argv);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment