summaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorDerrell Lipman <derrell.lipman@unwireduniverse.com>2008-01-16 14:37:40 +0000
committerDerrell Lipman <derrell.lipman@unwireduniverse.com>2008-01-16 14:37:40 +0000
commit296a6783fbc03460e87ac4136a0a9e6d2743b2ff (patch)
treeb5e81d44c2a26a7b23847dff8750975d75850876 /examples
parent01f6a4cca7a91ae41ff393263418216324502f84 (diff)
downloadsamba-296a6783fbc03460e87ac4136a0a9e6d2743b2ff.tar.gz
Replace GetTimeOfDay() with gettimeofday() in example program.
GetTimeOfDay() seems to no longer be exported. For the smbsh example, just use the native gettimeofday() for now.
Diffstat (limited to 'examples')
-rw-r--r--examples/libsmbclient/smbwrapper/select.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/examples/libsmbclient/smbwrapper/select.c b/examples/libsmbclient/smbwrapper/select.c
index 4e87a2e2e8e..bb7a25f13e8 100644
--- a/examples/libsmbclient/smbwrapper/select.c
+++ b/examples/libsmbclient/smbwrapper/select.c
@@ -72,13 +72,12 @@ int sys_select_intr(int maxfd, fd_set *readfds, fd_set *writefds, fd_set *errorf
int ret;
fd_set *readfds2, readfds_buf, *writefds2, writefds_buf, *errorfds2, errorfds_buf;
struct timeval tval2, *ptval, end_time, now_time;
- extern void GetTimeOfDay(struct timeval *tval);
readfds2 = (readfds ? &readfds_buf : NULL);
writefds2 = (writefds ? &writefds_buf : NULL);
errorfds2 = (errorfds ? &errorfds_buf : NULL);
if (tval) {
- GetTimeOfDay(&end_time);
+ gettimeofday(&end_time, NULL);
end_time.tv_sec += tval->tv_sec;
end_time.tv_usec += tval->tv_usec;
end_time.tv_sec += end_time.tv_usec / 1000000;
@@ -96,7 +95,7 @@ int sys_select_intr(int maxfd, fd_set *readfds, fd_set *writefds, fd_set *errorf
if (errorfds)
errorfds_buf = *errorfds;
if (tval) {
- GetTimeOfDay(&now_time);
+ gettimeofday(&now_time, NULL);
tval2.tv_sec = end_time.tv_sec - now_time.tv_sec;
tval2.tv_usec = end_time.tv_usec - now_time.tv_usec;
if ((signed long) tval2.tv_usec < 0) {