Hi tech@,
Small clean-up for encrypt(1) tool.
* remove includes that aren't needed (as built on amd64)
* move __progname into usage() because it's only used there
* function usage() is at top of file so it doesn't need forward declaration
- Michael
Index: encrypt.c
===================================================================
RCS file: /cvs/src/usr.bin/encrypt/encrypt.c,v
retrieving revision 1.42
diff -u -p -u -r1.42 encrypt.c
--- encrypt.c 10 Oct 2015 18:14:20 -0000 1.42
+++ encrypt.c 12 Nov 2015 08:05:55 -0000
@@ -25,32 +25,25 @@
* SUCH DAMAGE.
*/
-#include <sys/types.h>
-#include <ctype.h>
#include <err.h>
-#include <errno.h>
#include <pwd.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <login_cap.h>
-#include <limits.h>
/*
* Very simple little program, for encrypting passwords from the command
* line. Useful for scripts and such.
*/
-extern char *__progname;
-
-void usage(void);
-
#define DO_BLF 0
void
usage(void)
{
+ extern char *__progname;
(void)fprintf(stderr,
"usage: %s [-b rounds] [-c class] [-p | string]\n",