From: Ian Darwin Date: Thu, 21 May 1992 17:56:07 +0000 (+0000) Subject: Add New-C definitions for most cross-module functions. X-Git-Tag: FILE3_27~284 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=29256e78af322416274ccf239f40313c3c45e99a;p=file Add New-C definitions for most cross-module functions. --- diff --git a/src/file.h b/src/file.h index c03eba72..3bad6272 100644 --- a/src/file.h +++ b/src/file.h @@ -1,6 +1,6 @@ /* * file.h - definitions for file(1) program - # @(#)$Ident$ + * @(#)$Ident$ * * Copyright (c) Ian F. Darwin, 1987. * Written by Ian F. Darwin. @@ -54,4 +54,22 @@ struct magic { char desc[MAXDESC]; /* description */ }; +#if defined(__STDC__) || defined(__cplusplus) +int apprentice(char *fn, int check); +int ascmagic(unsigned char *buf, int nbytes); +void error(char *fmt, ...); +int fsmagic(char *fn); +int is_compress(unsigned char *p, int *b); +int is_tar(unsigned char *buf); +void mdump(struct magic *m); +parse(char *l, int *ndx, int check); +void process(char *inname); +void showstr(char *s); +int softmagic(unsigned char *buf, int nbytes); +void tryit(unsigned char *buf, int nb); +uncompress(unsigned char *old, unsigned char **newch, int n); +void warning(char *f, ...); +#else +/* error "Non-ANSI externs not written yet" */ extern void error(), exit(); +#endif