#include "file.h"
#ifndef lint
-static char *moduleid =
- "@(#)$Id: apprentice.c,v 1.25 1997/01/15 17:23:24 christos Exp $";
+FILE_RCSID("@(#)$Id: apprentice.c,v 1.26 1998/06/27 13:23:39 christos Exp $")
#endif /* lint */
#define EATAB {while (isascii((unsigned char) *l) && \
#include "names.h"
#ifndef lint
-static char *moduleid =
- "@(#)$Id: ascmagic.c,v 1.22 1998/02/15 23:18:53 christos Exp $";
+FILE_RCSID("@(#)$Id: ascmagic.c,v 1.23 1998/06/27 13:23:39 christos Exp $");
#endif /* lint */
/* an optimisation over plain strcmp() */
* information if recognized
* uncompress(method, old, n, newch) - uncompress old into new,
* using method, return sizeof new
- * $Id: compress.c,v 1.10 1998/02/15 23:18:53 christos Exp $
*/
#include <stdio.h>
#include <stdlib.h>
#ifdef HAVE_SYS_WAIT_H
#include <sys/wait.h>
#endif
-
#include "file.h"
+#ifndef lint
+FILE_RCSID("@(#)$Id: compress.c,v 1.11 1998/06/27 13:23:39 christos Exp $")
+#endif
+
static struct {
char *magic;
*
* 4. This notice may not be removed or altered.
*/
-#ifndef lint
-static char *moduleid =
- "@(#)$Id: file.c,v 1.39 1998/02/15 23:18:53 christos Exp $";
-#endif /* lint */
-
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "patchlevel.h"
#include "file.h"
+#ifndef lint
+FILE_RCSID("@(#)$Id: file.c,v 1.40 1998/06/27 13:23:39 christos Exp $")
+#endif /* lint */
+
+
#ifdef S_IFLNK
# define USAGE "Usage: %s [-vbczL] [-f namefile] [-m magicfiles] file...\n"
#else
/*
* file.h - definitions for file(1) program
- * @(#)$Id: file.h,v 1.25 1997/01/15 19:28:35 christos Exp $
+ * @(#)$Id: file.h,v 1.26 1998/06/27 13:23:39 christos Exp $
*
* Copyright (c) Ian F. Darwin, 1987.
* Written by Ian F. Darwin.
#define MAXPATHLEN 512
#endif
+#ifdef __STDC__
+#define FILE_RCSID(id) \
+static const char *rcsid(const char *p) { \
+ return rcsid(p = id); \
+}
+#else
+#define FILE_RCSID(id) static char *rcsid[] = id;
+#endif
+
#endif /* __file_h__ */
#include "file.h"
#ifndef lint
-static char *moduleid =
- "@(#)$Id: fsmagic.c,v 1.26 1998/02/15 23:18:53 christos Exp $";
+FILE_RCSID("@(#)$Id: fsmagic.c,v 1.27 1998/06/27 13:23:39 christos Exp $")
#endif /* lint */
int
#include <string.h>
#include <memory.h>
+#ifndef lint
+FILE_RCSID("@(#)$Id: internat.c,v 1.4 1998/06/27 13:23:39 christos Exp $")
+#endif
+
#define F 0
#define T 1
* Pubic Domain version written 26 Aug 1985 John Gilmore (ihnp4!hoptoad!gnu).
*
* @(#)list.c 1.18 9/23/86 Public Domain - gnu
- * $Id: is_tar.c,v 1.9 1997/01/15 17:23:24 christos Exp $
+ * $Id: is_tar.c,v 1.10 1998/06/27 13:23:39 christos Exp $
*
* Comments changed and some code/comments reformatted
* for file command by Ian Darwin.
#include <ctype.h>
#include <sys/types.h>
#include "tar.h"
+#include "file.h"
+
+#ifndef lint
+FILE_RCSID("@(#)$Id: is_tar.c,v 1.10 1998/06/27 13:23:39 christos Exp $")
+#endif
#define isodigit(c) ( ((c) >= '0') && ((c) <= '7') )
#include "file.h"
#ifndef lint
-static char *moduleid =
- "@(#)$Id: print.c,v 1.24 1997/04/13 18:28:30 christos Exp $";
+FILE_RCSID("@(#)$Id: print.c,v 1.25 1998/06/27 13:23:39 christos Exp $")
#endif /* lint */
#define SZOF(a) (sizeof(a) / sizeof(a[0]))
(m->type >= 0 && m->type < SZOF(typ)) ?
typ[(unsigned char) m->type] :
"*bad*");
- if (m->mask != ~0L)
+ if (m->mask != ~((uint32)0))
(void) fprintf(stderr, " & %.8x", m->mask);
(void) fprintf(stderr, ",%c", m->reln);
#include "readelf.h"
#include "file.h"
+#ifndef lint
+FILE_RCSID("@(#)$Id: readelf.c,v 1.7 1998/06/27 13:23:39 christos Exp $")
+#endif
+
static void
doshn(fd, off, num, size, buf)
int fd;
#include "file.h"
#ifndef lint
-static char *moduleid =
- "@(#)$Id: softmagic.c,v 1.36 1998/02/15 23:18:53 christos Exp $";
+FILE_RCSID("@(#)$Id: softmagic.c,v 1.37 1998/06/27 13:23:39 christos Exp $")
#endif /* lint */
static int match __P((unsigned char *, int));
{
char *pp, *rt;
uint32 v;
- time_t time;
+ time_t curtime;
int32 t=0 ;
case DATE:
case BEDATE:
case LEDATE:
- time = p->l;
- pp = ctime(&time);
+ curtime = p->l;
+ pp = ctime(&curtime);
if ((rt = strchr(pp, '\n')) != NULL)
*rt = '\0';
(void) printf(m->desc, pp);