401deb1bad
Adapt for db4 update post 4.5. Now dies with segfault during build: terminate called after throwing an instance of 'std::out_of_range' what(): basic_string::substr [1] Abort trap (core dumped) ./cstoreqptest 0...
28 lines
590 B
Text
28 lines
590 B
Text
$NetBSD: patch-ak,v 1.2 2011/12/20 13:42:47 wiz Exp $
|
|
|
|
--- src/Util/StopWatch.cpp.orig 2005-09-23 06:14:58.000000000 +0000
|
|
+++ src/Util/StopWatch.cpp
|
|
@@ -33,8 +33,9 @@
|
|
|
|
|
|
#include "StopWatch.h"
|
|
-#include <fstream.h>
|
|
-#include <iostream.h>
|
|
+#include <fstream>
|
|
+#include <iostream>
|
|
+using namespace std;
|
|
|
|
StopWatch::StopWatch()
|
|
{
|
|
@@ -52,6 +53,11 @@ void StopWatch::start() {
|
|
r1 = times(&t);
|
|
}
|
|
|
|
+// XXX would be better to get this value from sysctl
|
|
+#ifndef HZ
|
|
+#define HZ 100
|
|
+#endif
|
|
+
|
|
double StopWatch::stop() {
|
|
//clock_t diff = clock()-watch;
|
|
r2 = times(&u);
|