summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristos Zoulas <christos@zoulas.com>2009-02-03 20:27:51 +0000
committerChristos Zoulas <christos@zoulas.com>2009-02-03 20:27:51 +0000
commit2c287e38eacd6aec7b800db40373396bb5eb00f4 (patch)
tree650ba0944039685c0e056850591061a3856a9af8
parent595dcdabd5454a0d09379bafb169c9eced0337fd (diff)
downloadfile-git-2c287e38eacd6aec7b800db40373396bb5eb00f4.tar.gz
fix include files.FILE5_00
-rw-r--r--src/apprentice.c5
-rw-r--r--src/apptype.c3
-rw-r--r--src/ascmagic.c3
-rw-r--r--src/asprintf.c4
-rw-r--r--src/cdf.c11
-rw-r--r--src/cdf_time.c11
-rw-r--r--src/compress.c4
-rw-r--r--src/encoding.c8
-rw-r--r--src/file.c6
-rw-r--r--src/file.h3
-rw-r--r--src/fsmagic.c3
-rw-r--r--src/getopt_long.c3
-rw-r--r--src/is_tar.c3
-rw-r--r--src/magic.c6
-rw-r--r--src/print.c4
-rw-r--r--src/readcdf.c5
-rw-r--r--src/vasprintf.c3
17 files changed, 22 insertions, 63 deletions
diff --git a/src/apprentice.c b/src/apprentice.c
index 21cf1789..d78cb84c 100644
--- a/src/apprentice.c
+++ b/src/apprentice.c
@@ -32,7 +32,7 @@
#include "file.h"
#ifndef lint
-FILE_RCSID("@(#)$File: apprentice.c,v 1.145 2008/11/06 23:22:54 christos Exp $")
+FILE_RCSID("@(#)$File: apprentice.c,v 1.146 2008/11/07 18:57:08 christos Exp $")
#endif /* lint */
#include "magic.h"
@@ -45,12 +45,9 @@ FILE_RCSID("@(#)$File: apprentice.c,v 1.145 2008/11/06 23:22:54 christos Exp $")
#include <assert.h>
#include <ctype.h>
#include <fcntl.h>
-#include <sys/stat.h>
-#include <sys/param.h>
#ifdef QUICK
#include <sys/mman.h>
#endif
-#include <sys/types.h>
#include <dirent.h>
#define EATAB {while (isascii((unsigned char) *l) && \
diff --git a/src/apptype.c b/src/apptype.c
index 83569e9b..e02f730d 100644
--- a/src/apptype.c
+++ b/src/apptype.c
@@ -27,10 +27,9 @@
#include "file.h"
#ifndef lint
-FILE_RCSID("@(#)$File: apptype.c,v 1.8 2008/08/31 07:58:00 christos Exp $")
+FILE_RCSID("@(#)$File: apptype.c,v 1.9 2008/11/04 16:38:28 christos Exp $")
#endif /* lint */
-#include <stdio.h>
#include <stdlib.h>
#include <string.h>
diff --git a/src/ascmagic.c b/src/ascmagic.c
index b4c60630..61646031 100644
--- a/src/ascmagic.c
+++ b/src/ascmagic.c
@@ -36,11 +36,10 @@
#include "file.h"
#ifndef lint
-FILE_RCSID("@(#)$File: ascmagic.c,v 1.73 2008/11/07 18:57:28 christos Exp $")
+FILE_RCSID("@(#)$File: ascmagic.c,v 1.74 2008/11/07 19:10:25 christos Exp $")
#endif /* lint */
#include "magic.h"
-#include <stdio.h>
#include <string.h>
#include <memory.h>
#include <ctype.h>
diff --git a/src/asprintf.c b/src/asprintf.c
index deb4574e..d98e2250 100644
--- a/src/asprintf.c
+++ b/src/asprintf.c
@@ -29,11 +29,9 @@
#include "file.h"
#ifndef lint
-FILE_RCSID("@(#)$File: cdf.c,v 1.11 2008/11/03 05:34:27 christos Exp $")
+FILE_RCSID("@(#)$File: asprintf.c,v 1.2 2008/11/04 16:38:28 christos Exp $")
#endif
-#include <stdarg.h>
-
int vasprintf(char **ptr, const char *format_string, va_list vargs);
int asprintf(char **ptr, const char *fmt, ...)
diff --git a/src/cdf.c b/src/cdf.c
index f36a9f64..b81e8b67 100644
--- a/src/cdf.c
+++ b/src/cdf.c
@@ -32,27 +32,18 @@
#include "file.h"
#ifndef lint
-FILE_RCSID("@(#)$File: cdf.c,v 1.15 2008/12/03 22:49:41 christos Exp $")
+FILE_RCSID("@(#)$File: cdf.c,v 1.16 2008/12/12 20:53:02 christos Exp $")
#endif
#include <assert.h>
-#include <stdio.h>
#ifdef CDF_DEBUG
#include <err.h>
#endif
#include <stdlib.h>
#include <unistd.h>
-#include <errno.h>
-#include <fcntl.h>
#include <string.h>
#include <time.h>
#include <ctype.h>
-#ifdef HAVE_STDINT_H
-#include <stdint.h>
-#endif
-#ifdef HAVE_INTTYPES_H
-#include <inttypes.h>
-#endif
#ifndef EFTYPE
#define EFTYPE EINVAL
diff --git a/src/cdf_time.c b/src/cdf_time.c
index 71f9e7fb..9dbcad1f 100644
--- a/src/cdf_time.c
+++ b/src/cdf_time.c
@@ -27,23 +27,14 @@
#include "file.h"
#ifndef lint
-FILE_RCSID("@(#)$File: cdf.c,v 1.11 2008/11/03 05:34:27 christos Exp $")
+FILE_RCSID("@(#)$File: cdf_time.c,v 1.4 2008/11/04 16:38:28 christos Exp $")
#endif
-#include <sys/types.h>
-#include <stdio.h>
#include <time.h>
#ifdef TEST
#include <err.h>
#endif
#include <string.h>
-#include <errno.h>
-#ifdef HAVE_STDINT_H
-#include <stdint.h>
-#endif
-#ifdef HAVE_INTTYPES_H
-#include <inttypes.h>
-#endif
#include "cdf.h"
diff --git a/src/compress.c b/src/compress.c
index 16de2f25..0c2539d2 100644
--- a/src/compress.c
+++ b/src/compress.c
@@ -35,18 +35,16 @@
#include "file.h"
#ifndef lint
-FILE_RCSID("@(#)$File: compress.c,v 1.59 2008/11/22 17:01:28 chl Exp $")
+FILE_RCSID("@(#)$File: compress.c,v 1.60 2008/11/27 22:16:54 christos Exp $")
#endif
#include "magic.h"
-#include <stdio.h>
#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <string.h>
#include <errno.h>
-#include <sys/types.h>
#include <sys/ioctl.h>
#ifdef HAVE_SYS_WAIT_H
#include <sys/wait.h>
diff --git a/src/encoding.c b/src/encoding.c
index 223f6cbe..dbffd42a 100644
--- a/src/encoding.c
+++ b/src/encoding.c
@@ -33,14 +33,16 @@
*/
#include "file.h"
+
+#ifndef lint
+FILE_RCSID("@(#)$File: encoding.c,v 1.2 2008/11/06 22:49:08 rrt Exp $")
+#endif /* lint */
+
#include "magic.h"
#include <string.h>
#include <memory.h>
#include <stdlib.h>
-#ifndef lint
-FILE_RCSID("@(#)$File: encoding.c,v 1.1 2008/11/06 21:17:45 rrt Exp $")
-#endif /* lint */
private int looks_ascii(const unsigned char *, size_t, unichar *, size_t *);
private int looks_utf8_with_BOM(const unsigned char *, size_t, unichar *,
diff --git a/src/file.c b/src/file.c
index 98bae97d..806d2ec6 100644
--- a/src/file.c
+++ b/src/file.c
@@ -32,18 +32,14 @@
#include "file.h"
#ifndef lint
-FILE_RCSID("@(#)$File: file.c,v 1.128 2008/11/06 21:17:45 rrt Exp $")
+FILE_RCSID("@(#)$File: file.c,v 1.129 2008/12/03 18:05:18 christos Exp $")
#endif /* lint */
#include "magic.h"
-#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <string.h>
-#include <sys/types.h>
-#include <sys/param.h> /* for MAXPATHLEN */
-#include <sys/stat.h>
#ifdef RESTORE_TIME
# if (__COHERENT__ >= 0x420)
# include <sys/utime.h>
diff --git a/src/file.h b/src/file.h
index d616b265..c2bc47ed 100644
--- a/src/file.h
+++ b/src/file.h
@@ -27,7 +27,7 @@
*/
/*
* file.h - definitions for file(1) program
- * @(#)$File: file.h,v 1.116 2008/11/07 18:57:28 christos Exp $
+ * @(#)$File: file.h,v 1.117 2008/11/22 17:01:28 chl Exp $
*/
#ifndef __file_h__
@@ -48,6 +48,7 @@
#endif
#include <regex.h>
#include <sys/types.h>
+#include <sys/param.h>
/* Do this here and now, because struct stat gets re-defined on solaris */
#include <sys/stat.h>
#include <stdarg.h>
diff --git a/src/fsmagic.c b/src/fsmagic.c
index 96b5375d..ef3ceaeb 100644
--- a/src/fsmagic.c
+++ b/src/fsmagic.c
@@ -32,7 +32,7 @@
#include "file.h"
#ifndef lint
-FILE_RCSID("@(#)$File: fsmagic.c,v 1.57 2008/11/07 18:57:28 christos Exp $")
+FILE_RCSID("@(#)$File: fsmagic.c,v 1.58 2008/11/22 17:01:28 chl Exp $")
#endif /* lint */
#include "magic.h"
@@ -41,7 +41,6 @@ FILE_RCSID("@(#)$File: fsmagic.c,v 1.57 2008/11/07 18:57:28 christos Exp $")
#include <unistd.h>
#endif
#include <stdlib.h>
-#include <sys/stat.h>
/* Since major is a function on SVR4, we cannot use `ifndef major'. */
#ifdef MAJOR_IN_MKDEV
# include <sys/mkdev.h>
diff --git a/src/getopt_long.c b/src/getopt_long.c
index f81306ef..cb5c06a3 100644
--- a/src/getopt_long.c
+++ b/src/getopt_long.c
@@ -32,14 +32,13 @@
#include "file.h"
#ifndef lint
-FILE_RCSID("@(#)$File: funcs.c,v 1.46 2008/10/16 16:30:34 christos Exp $")
+FILE_RCSID("@(#)$File: getopt_long.c,v 1.4 2008/11/04 16:38:28 christos Exp $")
#endif /* lint */
#include <assert.h>
#ifdef HAVE_ERR_H
#include <err.h>
#else
-#include <stdio.h>
#define warnx printf
#endif
#include <errno.h>
diff --git a/src/is_tar.c b/src/is_tar.c
index 0da0308f..ab657d90 100644
--- a/src/is_tar.c
+++ b/src/is_tar.c
@@ -40,13 +40,12 @@
#include "file.h"
#ifndef lint
-FILE_RCSID("@(#)$File: is_tar.c,v 1.34 2008/11/04 16:38:28 christos Exp $")
+FILE_RCSID("@(#)$File: is_tar.c,v 1.35 2008/11/07 18:57:28 christos Exp $")
#endif
#include "magic.h"
#include <string.h>
#include <ctype.h>
-#include <sys/types.h>
#include "tar.h"
#define isodigit(c) ( ((c) >= '0') && ((c) <= '7') )
diff --git a/src/magic.c b/src/magic.c
index 6f884504..c2a2daf5 100644
--- a/src/magic.c
+++ b/src/magic.c
@@ -28,18 +28,14 @@
#include "file.h"
#ifndef lint
-FILE_RCSID("@(#)$File: magic.c,v 1.57 2008/11/22 17:01:28 chl Exp $")
+FILE_RCSID("@(#)$File: magic.c,v 1.58 2009/01/12 20:15:11 christos Exp $")
#endif /* lint */
#include "magic.h"
-#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <string.h>
-#include <sys/types.h>
-#include <sys/param.h> /* for MAXPATHLEN */
-#include <sys/stat.h>
#ifdef QUICK
#include <sys/mman.h>
#endif
diff --git a/src/print.c b/src/print.c
index 5f61a17e..632a18ed 100644
--- a/src/print.c
+++ b/src/print.c
@@ -32,11 +32,9 @@
#include "file.h"
#ifndef lint
-FILE_RCSID("@(#)$File: print.c,v 1.64 2008/10/20 15:14:17 christos Exp $")
+FILE_RCSID("@(#)$File: print.c,v 1.65 2008/11/04 16:38:28 christos Exp $")
#endif /* lint */
-#include <stdio.h>
-#include <errno.h>
#include <string.h>
#include <stdarg.h>
#include <stdlib.h>
diff --git a/src/readcdf.c b/src/readcdf.c
index a6126ce6..a036d6aa 100644
--- a/src/readcdf.c
+++ b/src/readcdf.c
@@ -26,14 +26,11 @@
#include "file.h"
#ifndef lint
-FILE_RCSID("@(#)$File: readcdf.c,v 1.9 2008/10/20 19:04:12 christos Exp $")
+FILE_RCSID("@(#)$File: readcdf.c,v 1.10 2008/12/03 22:54:02 christos Exp $")
#endif
-#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
-#include <errno.h>
-#include <fcntl.h>
#include <string.h>
#include <time.h>
#include <ctype.h>
diff --git a/src/vasprintf.c b/src/vasprintf.c
index 0e2affed..b285ad7d 100644
--- a/src/vasprintf.c
+++ b/src/vasprintf.c
@@ -108,11 +108,10 @@ you use strange formats.
#include "file.h"
#ifndef lint
-FILE_RCSID("@(#)$File: softmagic.c,v 1.125 2008/10/30 10:43:49 rrt Exp $")
+FILE_RCSID("@(#)$File: vasprintf.c,v 1.6 2008/11/04 16:38:28 christos Exp $")
#endif /* lint */
#include <assert.h>
-#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <stdarg.h>