diff options
Diffstat (limited to 'storage/tokudb/PerconaFT/src')
9 files changed, 26 insertions, 25 deletions
diff --git a/storage/tokudb/PerconaFT/src/tests/checkpoint_stress.cc b/storage/tokudb/PerconaFT/src/tests/checkpoint_stress.cc index 135a9843ce4..d3e5ddd5031 100644 --- a/storage/tokudb/PerconaFT/src/tests/checkpoint_stress.cc +++ b/storage/tokudb/PerconaFT/src/tests/checkpoint_stress.cc @@ -351,7 +351,7 @@ test_main (int argc, char * const argv[]) { // arg that suppresses valgrind on this child process break; } - // otherwise, fall through to an error + /* fall through */ // otherwise, fall through to an error case 'h': case '?': usage(argv[0]); diff --git a/storage/tokudb/PerconaFT/src/tests/directory_lock.cc b/storage/tokudb/PerconaFT/src/tests/directory_lock.cc index f040e680903..b28a71704cf 100644 --- a/storage/tokudb/PerconaFT/src/tests/directory_lock.cc +++ b/storage/tokudb/PerconaFT/src/tests/directory_lock.cc @@ -69,7 +69,7 @@ static void verify_shared_ops_fail(DB_ENV* env, DB* db) { uint32_t flags = 0; DBT key,val; DBT in_key,in_val; - uint32_t in_key_data, in_val_data = 0; + uint32_t in_key_data = 0, in_val_data = 0; memset(&in_key, 0, sizeof(in_key)); memset(&in_val, 0, sizeof(in_val)); in_key.size = sizeof(in_key_data); diff --git a/storage/tokudb/PerconaFT/src/tests/loader-cleanup-test.cc b/storage/tokudb/PerconaFT/src/tests/loader-cleanup-test.cc index ea894683c23..a229cb5b565 100644 --- a/storage/tokudb/PerconaFT/src/tests/loader-cleanup-test.cc +++ b/storage/tokudb/PerconaFT/src/tests/loader-cleanup-test.cc @@ -172,12 +172,12 @@ err_type_str (enum test_type t) { case einval_o: return "open"; case enospc_fc: return "fclose"; case abort_via_poll: return "abort_via_poll"; - case commit: assert(0); - case abort_txn: assert(0); - case abort_loader: assert(0); + case commit: abort(); + case abort_txn: abort(); + case abort_loader: abort(); } // I know that Barry prefers the single-return case, but writing the code this way means that the compiler will complain if I forget something in the enum. -Bradley - assert(0); + abort(); return NULL; } @@ -193,12 +193,12 @@ err_msg_type_str (enum test_type t) { case einval_o: return "EINVAL"; case enospc_fc: return "ENOSPC"; case abort_via_poll: return "non-zero"; - case commit: assert(0); - case abort_txn: assert(0); - case abort_loader: assert(0); + case commit: abort(); + case abort_txn: abort(); + case abort_loader: abort(); } // I know that Barry prefers the single-return case, but writing the code this way means that the compiler will complain if I forget something in the enum. -Bradley - assert(0); + abort(); return NULL; } @@ -873,7 +873,7 @@ static void run_test(enum test_type t, int trigger) case abort_via_poll: poll_count_trigger = trigger; break; default: - assert(0); + abort(); } diff --git a/storage/tokudb/PerconaFT/src/tests/recover-del-multiple-abort.cc b/storage/tokudb/PerconaFT/src/tests/recover-del-multiple-abort.cc index a8455c0f406..425c12e1a90 100644 --- a/storage/tokudb/PerconaFT/src/tests/recover-del-multiple-abort.cc +++ b/storage/tokudb/PerconaFT/src/tests/recover-del-multiple-abort.cc @@ -81,7 +81,7 @@ put_callback(DB *dest_db, DB *src_db, DBT_ARRAY *dest_keys, DBT_ARRAY *dest_vals memcpy(dest_key->data, &pri_data[dbnum], dest_key->size); break; default: - assert(0); + abort(); } if (dest_val) { @@ -95,9 +95,9 @@ put_callback(DB *dest_db, DB *src_db, DBT_ARRAY *dest_keys, DBT_ARRAY *dest_vals } break; case DB_DBT_REALLOC: - assert(0); + abort(); default: - assert(0); + abort(); } } diff --git a/storage/tokudb/PerconaFT/src/tests/recover-del-multiple-srcdb-fdelete-all.cc b/storage/tokudb/PerconaFT/src/tests/recover-del-multiple-srcdb-fdelete-all.cc index e823a74627d..75479cb69c4 100644 --- a/storage/tokudb/PerconaFT/src/tests/recover-del-multiple-srcdb-fdelete-all.cc +++ b/storage/tokudb/PerconaFT/src/tests/recover-del-multiple-srcdb-fdelete-all.cc @@ -85,7 +85,7 @@ put_callback(DB *dest_db, DB *src_db, DBT_ARRAY *dest_keys, DBT_ARRAY *dest_vals memcpy(dest_key->data, &pri_data[dbnum], dest_key->size); break; default: - assert(0); + abort(); } if (dest_val) { @@ -99,9 +99,9 @@ put_callback(DB *dest_db, DB *src_db, DBT_ARRAY *dest_keys, DBT_ARRAY *dest_vals } break; case DB_DBT_REALLOC: - assert(0); + abort(); default: - assert(0); + abort(); } } diff --git a/storage/tokudb/PerconaFT/src/tests/recover-del-multiple.cc b/storage/tokudb/PerconaFT/src/tests/recover-del-multiple.cc index c2ee80c438f..9f4b1cd9cb8 100644 --- a/storage/tokudb/PerconaFT/src/tests/recover-del-multiple.cc +++ b/storage/tokudb/PerconaFT/src/tests/recover-del-multiple.cc @@ -84,7 +84,7 @@ put_callback(DB *dest_db, DB *src_db, DBT_ARRAY *dest_keys, DBT_ARRAY *dest_vals memcpy(dest_key->data, &pri_data[dbnum], dest_key->size); break; default: - assert(0); + abort(); } if (dest_val) { @@ -98,9 +98,9 @@ put_callback(DB *dest_db, DB *src_db, DBT_ARRAY *dest_keys, DBT_ARRAY *dest_vals } break; case DB_DBT_REALLOC: - assert(0); + abort(); default: - assert(0); + abort(); } } diff --git a/storage/tokudb/PerconaFT/src/tests/recover-put-multiple-abort.cc b/storage/tokudb/PerconaFT/src/tests/recover-put-multiple-abort.cc index d045800960c..da40a61f24b 100644 --- a/storage/tokudb/PerconaFT/src/tests/recover-put-multiple-abort.cc +++ b/storage/tokudb/PerconaFT/src/tests/recover-put-multiple-abort.cc @@ -81,7 +81,7 @@ put_callback(DB *dest_db, DB *src_db, DBT_ARRAY *dest_keys, DBT_ARRAY *dest_vals memcpy(dest_key->data, &pri_data[dbnum], dest_key->size); break; default: - assert(0); + abort(); } if (dest_val) { @@ -95,9 +95,9 @@ put_callback(DB *dest_db, DB *src_db, DBT_ARRAY *dest_keys, DBT_ARRAY *dest_vals } break; case DB_DBT_REALLOC: - assert(0); + abort(); default: - assert(0); + abort(); } } diff --git a/storage/tokudb/PerconaFT/src/tests/recovery_fileops_unit.cc b/storage/tokudb/PerconaFT/src/tests/recovery_fileops_unit.cc index cc99ab560d8..45f0b465db4 100644 --- a/storage/tokudb/PerconaFT/src/tests/recovery_fileops_unit.cc +++ b/storage/tokudb/PerconaFT/src/tests/recovery_fileops_unit.cc @@ -158,7 +158,7 @@ do_args(int argc, char * const argv[]) { choices[i] = -1; } - char c; + signed char c; while ((c = getopt(argc, argv, "vqhcrO:A:B:C:D:E:F:G:H:I:J:X:")) != -1) { switch (c) { case 'v': @@ -217,7 +217,7 @@ do_args(int argc, char * const argv[]) { // arg that suppresses valgrind on this child process break; } - // otherwise, fall through to an error + /* fall through */ // otherwise, fall through to an error default: usage(); break; diff --git a/storage/tokudb/PerconaFT/src/tests/test-prepare3.cc b/storage/tokudb/PerconaFT/src/tests/test-prepare3.cc index 5cb3796a26b..f57fc963529 100644 --- a/storage/tokudb/PerconaFT/src/tests/test-prepare3.cc +++ b/storage/tokudb/PerconaFT/src/tests/test-prepare3.cc @@ -128,6 +128,7 @@ static void check_prepared_list (enum prepared_state ps[NTXNS], long count, DB_P goto next; case PREPARED: count_prepared++; + /* fall through */ case MAYBE_COMMITTED: case MAYBE_ABORTED: count_maybe_prepared++; |