summaryrefslogtreecommitdiff
path: root/misc.h
diff options
context:
space:
mode:
Diffstat (limited to 'misc.h')
-rw-r--r--misc.h11
1 files changed, 9 insertions, 2 deletions
diff --git a/misc.h b/misc.h
index 31b207a8d..5b4325aba 100644
--- a/misc.h
+++ b/misc.h
@@ -1,4 +1,4 @@
1/* $OpenBSD: misc.h,v 1.75 2018/10/03 06:38:35 djm Exp $ */ 1/* $OpenBSD: misc.h,v 1.79 2019/01/23 21:50:56 dtucker Exp $ */
2 2
3/* 3/*
4 * Author: Tatu Ylonen <ylo@cs.hut.fi> 4 * Author: Tatu Ylonen <ylo@cs.hut.fi>
@@ -17,6 +17,7 @@
17 17
18#include <sys/time.h> 18#include <sys/time.h>
19#include <sys/types.h> 19#include <sys/types.h>
20#include <sys/socket.h>
20 21
21/* Data structure for representing a forwarding request. */ 22/* Data structure for representing a forwarding request. */
22struct Forward { 23struct Forward {
@@ -51,9 +52,12 @@ void set_nodelay(int);
51int set_reuseaddr(int); 52int set_reuseaddr(int);
52char *get_rdomain(int); 53char *get_rdomain(int);
53int set_rdomain(int, const char *); 54int set_rdomain(int, const char *);
55int waitrfd(int, int *);
56int timeout_connect(int, const struct sockaddr *, socklen_t, int *);
54int a2port(const char *); 57int a2port(const char *);
55int a2tun(const char *, int *); 58int a2tun(const char *, int *);
56char *put_host_port(const char *, u_short); 59char *put_host_port(const char *, u_short);
60char *hpdelim2(char **, char *);
57char *hpdelim(char **); 61char *hpdelim(char **);
58char *cleanhostname(char *); 62char *cleanhostname(char *);
59char *colon(char *); 63char *colon(char *);
@@ -78,6 +82,7 @@ int valid_env_name(const char *);
78const char *atoi_err(const char *, int *); 82const char *atoi_err(const char *, int *);
79int parse_absolute_time(const char *, uint64_t *); 83int parse_absolute_time(const char *, uint64_t *);
80void format_absolute_time(uint64_t, char *, size_t); 84void format_absolute_time(uint64_t, char *, size_t);
85int path_absolute(const char *);
81 86
82void sock_set_v6only(int); 87void sock_set_v6only(int);
83 88
@@ -134,7 +139,9 @@ void put_u32_le(void *, u_int32_t)
134 139
135struct bwlimit { 140struct bwlimit {
136 size_t buflen; 141 size_t buflen;
137 u_int64_t rate, thresh, lamt; 142 u_int64_t rate; /* desired rate in kbit/s */
143 u_int64_t thresh; /* threshold after which we'll check timers */
144 u_int64_t lamt; /* amount written in last timer interval */
138 struct timeval bwstart, bwend; 145 struct timeval bwstart, bwend;
139}; 146};
140 147