summaryrefslogtreecommitdiff
path: root/misc.h
diff options
context:
space:
mode:
Diffstat (limited to 'misc.h')
-rw-r--r--misc.h10
1 files changed, 9 insertions, 1 deletions
diff --git a/misc.h b/misc.h
index 42cd95e42..8b223b55e 100644
--- a/misc.h
+++ b/misc.h
@@ -1,4 +1,4 @@
1/* $OpenBSD: misc.h,v 1.57 2016/07/15 00:24:30 djm Exp $ */ 1/* $OpenBSD: misc.h,v 1.61 2016/11/30 00:28:31 dtucker Exp $ */
2 2
3/* 3/*
4 * Author: Tatu Ylonen <ylo@cs.hut.fi> 4 * Author: Tatu Ylonen <ylo@cs.hut.fi>
@@ -15,6 +15,8 @@
15#ifndef _MISC_H 15#ifndef _MISC_H
16#define _MISC_H 16#define _MISC_H
17 17
18#include <sys/time.h>
19
18/* Data structure for representing a forwarding request. */ 20/* Data structure for representing a forwarding request. */
19struct Forward { 21struct Forward {
20 char *listen_host; /* Host (address) to listen on. */ 22 char *listen_host; /* Host (address) to listen on. */
@@ -28,6 +30,8 @@ struct Forward {
28}; 30};
29 31
30int forward_equals(const struct Forward *, const struct Forward *); 32int forward_equals(const struct Forward *, const struct Forward *);
33int bind_permitted(int, uid_t);
34int daemonized(void);
31 35
32/* Common server and client forwarding options. */ 36/* Common server and client forwarding options. */
33struct ForwardOptions { 37struct ForwardOptions {
@@ -141,4 +145,8 @@ int read_keyfile_line(FILE *, const char *, char *, size_t, u_long *);
141 145
142int secure_permissions(struct stat *st, uid_t uid); 146int secure_permissions(struct stat *st, uid_t uid);
143 147
148#define MINIMUM(a, b) (((a) < (b)) ? (a) : (b))
149#define MAXIMUM(a, b) (((a) > (b)) ? (a) : (b))
150#define ROUNDUP(x, y) ((((x)+((y)-1))/(y))*(y))
151
144#endif /* _MISC_H */ 152#endif /* _MISC_H */