diff options
author | Damien Miller <djm@mindrot.org> | 2003-05-19 00:13:38 +1000 |
---|---|---|
committer | Damien Miller <djm@mindrot.org> | 2003-05-19 00:13:38 +1000 |
commit | 317412502b900ddecdafdfa171da99271846478b (patch) | |
tree | 2e04f618288cdf0c16a98b675b28b8287a15a0c6 /openbsd-compat/bsd-misc.h | |
parent | e323df6c4851b04386e747a009474f469fe97137 (diff) |
- (djm) Big KNF on openbsd-compat/
Diffstat (limited to 'openbsd-compat/bsd-misc.h')
-rw-r--r-- | openbsd-compat/bsd-misc.h | 27 |
1 files changed, 13 insertions, 14 deletions
diff --git a/openbsd-compat/bsd-misc.h b/openbsd-compat/bsd-misc.h index 78d9ccdd4..00e508cfc 100644 --- a/openbsd-compat/bsd-misc.h +++ b/openbsd-compat/bsd-misc.h | |||
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | * Copyright (c) 1999-2000 Damien Miller. All rights reserved. | 2 | * Copyright (c) 1999-2003 Damien Miller. All rights reserved. |
3 | * | 3 | * |
4 | * Redistribution and use in source and binary forms, with or without | 4 | * Redistribution and use in source and binary forms, with or without |
5 | * modification, are permitted provided that the following conditions | 5 | * modification, are permitted provided that the following conditions |
@@ -22,42 +22,41 @@ | |||
22 | * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 22 | * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
23 | */ | 23 | */ |
24 | 24 | ||
25 | /* $Id: bsd-misc.h,v 1.7 2003/03/18 18:21:41 tim Exp $ */ | 25 | /* $Id: bsd-misc.h,v 1.8 2003/05/18 14:13:39 djm Exp $ */ |
26 | 26 | ||
27 | #ifndef _BSD_MISC_H | 27 | #ifndef _BSD_MISC_H |
28 | #define _BSD_MISC_H | 28 | #define _BSD_MISC_H |
29 | 29 | ||
30 | #include "config.h" | 30 | #include "config.h" |
31 | 31 | ||
32 | char *get_progname(char *argv0); | 32 | char *get_progname(char *); |
33 | 33 | ||
34 | #ifndef HAVE_SETSID | 34 | #ifndef HAVE_SETSID |
35 | #define setsid() setpgrp(0, getpid()) | 35 | #define setsid() setpgrp(0, getpid()) |
36 | #endif /* !HAVE_SETSID */ | 36 | #endif /* !HAVE_SETSID */ |
37 | 37 | ||
38 | #ifndef HAVE_SETENV | 38 | #ifndef HAVE_SETENV |
39 | int setenv(const char *name, const char *value, int overwrite); | 39 | int setenv(const char *, const char *, int); |
40 | #endif /* !HAVE_SETENV */ | 40 | #endif /* !HAVE_SETENV */ |
41 | 41 | ||
42 | #ifndef HAVE_SETLOGIN | 42 | #ifndef HAVE_SETLOGIN |
43 | int setlogin(const char *name); | 43 | int setlogin(const char *); |
44 | #endif /* !HAVE_SETLOGIN */ | 44 | #endif /* !HAVE_SETLOGIN */ |
45 | 45 | ||
46 | #ifndef HAVE_INNETGR | 46 | #ifndef HAVE_INNETGR |
47 | int innetgr(const char *netgroup, const char *host, | 47 | int innetgr(const char *, const char *, const char *, const char *); |
48 | const char *user, const char *domain); | ||
49 | #endif /* HAVE_INNETGR */ | 48 | #endif /* HAVE_INNETGR */ |
50 | 49 | ||
51 | #if !defined(HAVE_SETEUID) && defined(HAVE_SETREUID) | 50 | #if !defined(HAVE_SETEUID) && defined(HAVE_SETREUID) |
52 | int seteuid(uid_t euid); | 51 | int seteuid(uid_t); |
53 | #endif /* !defined(HAVE_SETEUID) && defined(HAVE_SETREUID) */ | 52 | #endif /* !defined(HAVE_SETEUID) && defined(HAVE_SETREUID) */ |
54 | 53 | ||
55 | #if !defined(HAVE_SETEGID) && defined(HAVE_SETRESGID) | 54 | #if !defined(HAVE_SETEGID) && defined(HAVE_SETRESGID) |
56 | int setegid(uid_t egid); | 55 | int setegid(uid_t); |
57 | #endif /* !defined(HAVE_SETEGID) && defined(HAVE_SETRESGID) */ | 56 | #endif /* !defined(HAVE_SETEGID) && defined(HAVE_SETRESGID) */ |
58 | 57 | ||
59 | #if !defined(HAVE_STRERROR) && defined(HAVE_SYS_ERRLIST) && defined(HAVE_SYS_NERR) | 58 | #if !defined(HAVE_STRERROR) && defined(HAVE_SYS_ERRLIST) && defined(HAVE_SYS_NERR) |
60 | const char *strerror(int e); | 59 | const char *strerror(int); |
61 | #endif | 60 | #endif |
62 | 61 | ||
63 | 62 | ||
@@ -69,15 +68,15 @@ struct timeval { | |||
69 | } | 68 | } |
70 | #endif /* HAVE_STRUCT_TIMEVAL */ | 69 | #endif /* HAVE_STRUCT_TIMEVAL */ |
71 | 70 | ||
72 | int utimes(char *filename, struct timeval *tvp); | 71 | int utimes(char *, struct timeval *); |
73 | #endif /* HAVE_UTIMES */ | 72 | #endif /* HAVE_UTIMES */ |
74 | 73 | ||
75 | #ifndef HAVE_TRUNCATE | 74 | #ifndef HAVE_TRUNCATE |
76 | int truncate (const char *path, off_t length); | 75 | int truncate (const char *, off_t); |
77 | #endif /* HAVE_TRUNCATE */ | 76 | #endif /* HAVE_TRUNCATE */ |
78 | 77 | ||
79 | #if !defined(HAVE_SETGROUPS) && defined(SETGROUPS_NOOP) | 78 | #if !defined(HAVE_SETGROUPS) && defined(SETGROUPS_NOOP) |
80 | int setgroups(size_t size, const gid_t *list); | 79 | int setgroups(size_t, const gid_t *); |
81 | #endif | 80 | #endif |
82 | 81 | ||
83 | #if !defined(HAVE_NANOSLEEP) && !defined(HAVE_NSLEEP) | 82 | #if !defined(HAVE_NANOSLEEP) && !defined(HAVE_NSLEEP) |
@@ -87,7 +86,7 @@ struct timespec { | |||
87 | long tv_nsec; | 86 | long tv_nsec; |
88 | }; | 87 | }; |
89 | #endif | 88 | #endif |
90 | int nanosleep(const struct timespec *req, struct timespec *rem); | 89 | int nanosleep(const struct timespec *, struct timespec *); |
91 | #endif | 90 | #endif |
92 | 91 | ||
93 | #endif /* _BSD_MISC_H */ | 92 | #endif /* _BSD_MISC_H */ |