diff options
author | Don Anderson <dda@mongodb.com> | 2016-09-14 19:05:00 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-09-14 19:05:00 -0400 |
commit | 10dd36a9bf507e13d2d17ff72d9d55a88aae2f12 (patch) | |
tree | 0b2eb5165d0527bda72aabc734d5320a5be67a90 | |
parent | e189aa8a3de76fcd71a4dea254a24f02c80dfa19 (diff) | |
download | mongo-10dd36a9bf507e13d2d17ff72d9d55a88aae2f12.tar.gz |
WT-2914 In test/csuite program, added explicit call to wiredtiger_open to satisfy some linkers (#3040)
-rw-r--r-- | test/csuite/wt2695_checksum/main.c | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/test/csuite/wt2695_checksum/main.c b/test/csuite/wt2695_checksum/main.c index df6f562f719..afb9d0788bd 100644 --- a/test/csuite/wt2695_checksum/main.c +++ b/test/csuite/wt2695_checksum/main.c @@ -44,22 +44,27 @@ check(uint32_t hw, uint32_t sw, size_t len, const char *msg) #define DATASIZE (128 * 1024) int -main(void) +main(int argc, char *argv[]) { + TEST_OPTS *opts, _opts; WT_RAND_STATE rnd; size_t len; uint32_t hw, sw; u_int i, j; uint8_t *data; - /* Allocate aligned memory for the data. */ - data = dcalloc(DATASIZE, sizeof(uint8_t)); + opts = &_opts; + memset(opts, 0, sizeof(*opts)); + testutil_check(testutil_parse_opts(argc, argv, opts)); + testutil_make_work_dir(opts->home); + testutil_check( + wiredtiger_open(opts->home, NULL, "create", &opts->conn)); /* Initialize the RNG. */ testutil_check(__wt_random_init_seed(NULL, &rnd)); - /* Initialize the WiredTiger library checksum functions. */ - __wt_checksum_init(); + /* Allocate aligned memory for the data. */ + data = dcalloc(DATASIZE, sizeof(uint8_t)); /* * Some simple known checksums. @@ -139,5 +144,6 @@ main(void) } free(data); + testutil_cleanup(opts); return (EXIT_SUCCESS); } |