summaryrefslogtreecommitdiffstats
path: root/usr.sbin/netgroup_mkdb
diff options
context:
space:
mode:
authorderaadt <deraadt@openbsd.org>2004-08-01 18:32:17 +0000
committerderaadt <deraadt@openbsd.org>2004-08-01 18:32:17 +0000
commitf56bb1bd7ef91597b1c308891aae151d18bc0ac7 (patch)
tree9a33a25799920e408838c931715eda1fa2e2f5bc /usr.sbin/netgroup_mkdb
parentTrim include file list. (diff)
downloadwireguard-openbsd-f56bb1bd7ef91597b1c308891aae151d18bc0ac7.tar.xz
wireguard-openbsd-f56bb1bd7ef91597b1c308891aae151d18bc0ac7.zip
ansi cleanup; khalek@linuxgamers.net
Diffstat (limited to 'usr.sbin/netgroup_mkdb')
-rw-r--r--usr.sbin/netgroup_mkdb/str.c18
-rw-r--r--usr.sbin/netgroup_mkdb/util.c13
2 files changed, 9 insertions, 22 deletions
diff --git a/usr.sbin/netgroup_mkdb/str.c b/usr.sbin/netgroup_mkdb/str.c
index e107d409c98..4b2923c6e33 100644
--- a/usr.sbin/netgroup_mkdb/str.c
+++ b/usr.sbin/netgroup_mkdb/str.c
@@ -30,7 +30,7 @@
*/
#ifndef lint
-static char *rcsid = "$Id: str.c,v 1.1.1.1 1995/10/18 08:47:57 deraadt Exp $";
+static char *rcsid = "$Id: str.c,v 1.2 2004/08/01 18:32:20 deraadt Exp $";
#endif
/*
@@ -46,8 +46,7 @@ static char *rcsid = "$Id: str.c,v 1.1.1.1 1995/10/18 08:47:57 deraadt Exp $";
* str_init(): Initialize string
*/
void
-str_init(s)
- struct string *s;
+str_init(struct string *s)
{
s->s_str = NULL;
s->s_len = 0;
@@ -58,10 +57,7 @@ str_init(s)
* str_append(): Append string allocating buffer as necessary
*/
void
-str_append(buf, str, del)
- struct string *buf;
- const char *str;
- int del;
+str_append(struct string *buf, const char *str, int del)
{
size_t len = strlen(str) + 1;
@@ -82,10 +78,7 @@ str_append(buf, str, del)
* str_prepend(): Prepend string allocating buffer as necessary
*/
void
-str_prepend(buf, str, del)
- struct string *buf;
- const char *str;
- int del;
+str_prepend(struct string *buf, const char *str, int del)
{
char *ptr, *sptr;
size_t len = strlen(str) + 1;
@@ -110,8 +103,7 @@ str_prepend(buf, str, del)
* str_free(): Free a string
*/
void
-str_free(s)
- struct string *s;
+str_free(struct string *s)
{
free(s->s_str);
s->s_str = NULL;
diff --git a/usr.sbin/netgroup_mkdb/util.c b/usr.sbin/netgroup_mkdb/util.c
index b418409caf2..7c83232c1ca 100644
--- a/usr.sbin/netgroup_mkdb/util.c
+++ b/usr.sbin/netgroup_mkdb/util.c
@@ -30,7 +30,7 @@
*/
#ifndef lint
-static char *rcsid = "$Id: util.c,v 1.2 1997/04/15 15:06:13 deraadt Exp $";
+static char *rcsid = "$Id: util.c,v 1.3 2004/08/01 18:32:20 deraadt Exp $";
#endif
#include <err.h>
@@ -43,8 +43,7 @@ static char *rcsid = "$Id: util.c,v 1.2 1997/04/15 15:06:13 deraadt Exp $";
* Error checked malloc
*/
void *
-emalloc(s)
- size_t s;
+emalloc(size_t s)
{
void *ptr = malloc(s);
if (ptr == NULL)
@@ -58,9 +57,7 @@ emalloc(s)
* Error checked realloc
*/
void *
-erealloc(p, s)
- void *p;
- size_t s;
+erealloc(void *p, size_t s)
{
void *ptr = realloc(p, s);
if (ptr == NULL)
@@ -75,9 +72,7 @@ erealloc(p, s)
* and eliminating trailing newlines.
*/
char *
-getline(fp, size)
- FILE *fp;
- size_t *size;
+getline(FILE *fp, size_t *size)
{
size_t s, len = 0;
char *buf = NULL;