summaryrefslogtreecommitdiffstats
path: root/usr.sbin/crunch/crunchide
diff options
context:
space:
mode:
authorobrien <obrien@FreeBSD.org>2012-06-27 04:39:30 +0000
committerobrien <obrien@FreeBSD.org>2012-06-27 04:39:30 +0000
commit7ade5e92e5aeed2f2932f313b5a0255c6777538c (patch)
tree244e3fdb9591648048fa7d3da4c6d1b9967abb1b /usr.sbin/crunch/crunchide
parentbc23332ce7bed6bcbb1db9452d848c63a713e7c2 (diff)
downloadFreeBSD-src-7ade5e92e5aeed2f2932f313b5a0255c6777538c.zip
FreeBSD-src-7ade5e92e5aeed2f2932f313b5a0255c6777538c.tar.gz
Some amount of style(9)
-- function definitions, header ordering, and $FreeBSD$.
Diffstat (limited to 'usr.sbin/crunch/crunchide')
-rw-r--r--usr.sbin/crunch/crunchide/crunchide.c29
1 files changed, 17 insertions, 12 deletions
diff --git a/usr.sbin/crunch/crunchide/crunchide.c b/usr.sbin/crunch/crunchide/crunchide.c
index 32c42db..d2b1123 100644
--- a/usr.sbin/crunch/crunchide/crunchide.c
+++ b/usr.sbin/crunch/crunchide/crunchide.c
@@ -1,5 +1,4 @@
/* $NetBSD: crunchide.c,v 1.8 1997/11/01 06:51:45 lukem Exp $ */
-/* $FreeBSD$ */
/*
* Copyright (c) 1997 Christopher G. Demetriou. All rights reserved.
* Copyright (c) 1994 University of Maryland
@@ -59,20 +58,22 @@
* that the final crunched binary BSS size is the max of all the
* component programs' BSS sizes, rather than their sum.
*/
+
#include <sys/cdefs.h>
#ifndef lint
__RCSID("$NetBSD: crunchide.c,v 1.8 1997/11/01 06:51:45 lukem Exp $");
#endif
+__FBSDID("$FreeBSD$");
+#include <sys/types.h>
+#include <sys/stat.h>
+#include <sys/errno.h>
#include <unistd.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <fcntl.h>
#include <a.out.h>
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <sys/errno.h>
#include "extern.h"
@@ -89,9 +90,8 @@ int verbose;
int main(int, char *[]);
-int main(argc, argv)
-int argc;
-char **argv;
+int
+main(int argc, char **argv)
{
int ch, errors;
@@ -127,7 +127,8 @@ char **argv;
return errors;
}
-void usage(void)
+void
+usage(void)
{
fprintf(stderr,
"usage: %s [-k <symbol-name>] [-f <keep-list-file>] <files> ...\n",
@@ -142,7 +143,8 @@ struct keep {
char *sym;
} *keep_list;
-void add_to_keep_list(char *symbol)
+void
+add_to_keep_list(char *symbol)
{
struct keep *newp, *prevp, *curp;
int cmp;
@@ -167,7 +169,8 @@ void add_to_keep_list(char *symbol)
else keep_list = newp;
}
-int in_keep_list(const char *symbol)
+int
+in_keep_list(const char *symbol)
{
struct keep *curp;
int cmp;
@@ -180,7 +183,8 @@ int in_keep_list(const char *symbol)
return curp && cmp == 0;
}
-void add_file_to_keep_list(char *filename)
+void
+add_file_to_keep_list(char *filename)
{
FILE *keepf;
char symbol[1024];
@@ -222,7 +226,8 @@ struct {
#endif
};
-int hide_syms(const char *filename)
+int
+hide_syms(const char *filename)
{
int fd, i, n, rv;
OpenPOWER on IntegriCloud