summaryrefslogtreecommitdiff
path: root/textproc/xerces-c
diff options
context:
space:
mode:
authorskrll <skrll>2001-01-14 12:18:30 +0000
committerskrll <skrll>2001-01-14 12:18:30 +0000
commit00e922a459af6299575ac5ee9b016541d56ae2e7 (patch)
tree728b2da680cea6bb18a9114b331cf645ce041d45 /textproc/xerces-c
parente64557d780a4350239657841a0e81c4f6516ce81 (diff)
downloadpkgsrc-00e922a459af6299575ac5ee9b016541d56ae2e7.tar.gz
Use gettimeofday instead of ftime.
Diffstat (limited to 'textproc/xerces-c')
-rw-r--r--textproc/xerces-c/files/Makefile.in1
-rw-r--r--textproc/xerces-c/files/NetBSDPlatformUtils.cpp9
2 files changed, 5 insertions, 5 deletions
diff --git a/textproc/xerces-c/files/Makefile.in b/textproc/xerces-c/files/Makefile.in
index c1bd3129ce4..8184d97c8cf 100644
--- a/textproc/xerces-c/files/Makefile.in
+++ b/textproc/xerces-c/files/Makefile.in
@@ -79,4 +79,3 @@ CPP_OBJECTS = NetBSDPlatformUtils.$(TO)
include ../../Makefile.util.submodule
-CPP_OBJECTS: NetBSDPlatformUtils.cpp ${CPP_PUBHEADERS}
diff --git a/textproc/xerces-c/files/NetBSDPlatformUtils.cpp b/textproc/xerces-c/files/NetBSDPlatformUtils.cpp
index 34b74dcb11a..8da8f3a17bf 100644
--- a/textproc/xerces-c/files/NetBSDPlatformUtils.cpp
+++ b/textproc/xerces-c/files/NetBSDPlatformUtils.cpp
@@ -77,7 +77,7 @@
#include <stdlib.h>
#include <errno.h>
#include <libgen.h>
-#include <sys/timeb.h>
+#include <sys/time.h>
#include <string.h>
#include <strings.h>/* for strcasecmp & strncasecmp */
#include <wchar.h> /* for win_t */
@@ -450,10 +450,11 @@ void XMLPlatformUtils::resetFile(FileHandle theFile)
unsigned long XMLPlatformUtils::getCurrentMillis()
{
- timeb aTime;
- ftime(&aTime);
- return (unsigned long)(aTime.time*1000 + aTime.millitm);
+ struct timeval t;
+ struct timezone tz;
+ gettimeofday(&t, &tz);
+ return (unsigned long)(t.tv_sec*1000 + t.tv_usec);
}
XMLCh* XMLPlatformUtils::getFullPath(const XMLCh* const srcPath)