Skip to content

Commit

Permalink
chore: print errors if any
Browse files Browse the repository at this point in the history
  • Loading branch information
gocarlos authored Mar 18, 2020
1 parent cd2f8fd commit c0658b2
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion recipes/rocksdb/all/test_package/test_package.cpp
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
#include <cstdlib>
#include <iostream>
#include "rocksdb/db.h"

int main() {
rocksdb::DB* db;
rocksdb::Options options;
options.create_if_missing = true;
rocksdb::Status status = rocksdb::DB::Open(options, "testdb", &db);
status.ok();

if (!status.ok()) {
std::cerr << "DB error: " << status.ToString();
}

return EXIT_SUCCESS;
}

0 comments on commit c0658b2

Please sign in to comment.