diff options
author | Daniel Stenberg <daniel@haxx.se> | 2017-07-28 15:49:36 +0200 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2017-07-28 15:51:25 +0200 |
commit | 4dee50b9c80f9b18d2eb9a1c20bd879abb342302 (patch) | |
tree | 7a9c5ddd299e23ad27c7efa6a8759ae3122f31c9 /lib/splay.h | |
parent | 7551e55d6614cddb039602e08f3d7aa302299617 (diff) | |
download | curl-4dee50b9c80f9b18d2eb9a1c20bd879abb342302.tar.gz |
timeval: struct curltime is a struct timeval replacement
... to make all libcurl internals able to use the same data types for
the struct members. The timeval struct differs subtly on several
platforms so it makes it cumbersome to use everywhere.
Ref: #1652
Closes #1693
Diffstat (limited to 'lib/splay.h')
-rw-r--r-- | lib/splay.h | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/lib/splay.h b/lib/splay.h index da81894d1..0273bad38 100644 --- a/lib/splay.h +++ b/lib/splay.h @@ -7,7 +7,7 @@ * | (__| |_| | _ <| |___ * \___|\___/|_| \_\_____| * - * Copyright (C) 1997 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al. + * Copyright (C) 1997 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al. * * This software is licensed as described in the file COPYING, which * you should have received as part of this distribution. The terms @@ -22,30 +22,31 @@ * ***************************************************************************/ #include "curl_setup.h" +#include "timeval.h" struct Curl_tree { struct Curl_tree *smaller; /* smaller node */ struct Curl_tree *larger; /* larger node */ struct Curl_tree *samen; /* points to the next node with identical key */ struct Curl_tree *samep; /* points to the prev node with identical key */ - struct timeval key; /* this node's "sort" key */ + struct curltime key; /* this node's "sort" key */ void *payload; /* data the splay code doesn't care about */ }; -struct Curl_tree *Curl_splay(struct timeval i, +struct Curl_tree *Curl_splay(struct curltime i, struct Curl_tree *t); -struct Curl_tree *Curl_splayinsert(struct timeval key, +struct Curl_tree *Curl_splayinsert(struct curltime key, struct Curl_tree *t, struct Curl_tree *newnode); #if 0 -struct Curl_tree *Curl_splayremove(struct timeval key, +struct Curl_tree *Curl_splayremove(struct curltime key, struct Curl_tree *t, struct Curl_tree **removed); #endif -struct Curl_tree *Curl_splaygetbest(struct timeval key, +struct Curl_tree *Curl_splaygetbest(struct curltime key, struct Curl_tree *t, struct Curl_tree **removed); |