X-Git-Url: http://mj.ucw.cz/gitweb/?a=blobdiff_plain;ds=sidebyside;f=lib%2Fdb-test.c;h=9a6f3bb6264e19620970226474d15ab85d7bb083;hb=46ddff89cca52f48ad1ed9eda5d5d9aa0b2f5ea5;hp=b1694223e99f12114a97162acfddd70c1ca72559;hpb=9e6d7b0a077eb2914150301fb96180e80a370658;p=libucw.git diff --git a/lib/db-test.c b/lib/db-test.c index b1694223..9a6f3bb6 100644 --- a/lib/db-test.c +++ b/lib/db-test.c @@ -1,18 +1,21 @@ /* - * Sherlock Library -- Database Manager -- Tests and Benchmarks + * UCW Library -- Database Manager -- Tests and Benchmarks * - * (c) 1999 Martin Mares + * (c) 1999 Martin Mares + * + * This software may be freely distributed and used according to the terms + * of the GNU Lesser General Public License. */ #if 1 -#include "db.c" +#include "lib/db.c" #define NAME "SDBM" #else -#include "db-emul.c" +#include "lib/db-emul.c" #define NAME "GDBM" #endif -#include +#include #include #include #include @@ -259,8 +262,9 @@ int main(int argc, char **argv) uns ks, vs, vs2, perc, cnt; char *ch; int dont_delete = 0; + timestamp_t timer; - initlog("dbtest"); + log_init("dbtest"); setvbuf(stdout, NULL, _IONBF, 0); setvbuf(stderr, NULL, _IONBF, 0); while ((c = getopt(argc, argv, "c:p:k:n:d:vsStF")) >= 0) @@ -330,7 +334,7 @@ int main(int argc, char **argv) while (optind < argc) { char *o = argv[optind++]; - init_timer(); + init_timer(&timer); switch (*o) { case 'c': @@ -456,7 +460,7 @@ int main(int argc, char **argv) help(); } sdbm_sync(d); - printf("%d ms\n", get_timer()); + printf("%d ms\n", get_timer(&timer)); } verb("CLOSE\n");