summaryrefslogtreecommitdiffstats
path: root/contrib/file/src/file.h
diff options
context:
space:
mode:
authordelphij <delphij@FreeBSD.org>2015-01-23 18:48:59 +0000
committerdelphij <delphij@FreeBSD.org>2015-01-23 18:48:59 +0000
commit606dfe10754ec3dbe1055a9ab1e26f94dd25282b (patch)
treead6b6f423e47801e60bdd11239c19553a525dad3 /contrib/file/src/file.h
parentb62501e2c26308009af2e269236ed99f01f67d98 (diff)
downloadFreeBSD-src-606dfe10754ec3dbe1055a9ab1e26f94dd25282b.zip
FreeBSD-src-606dfe10754ec3dbe1055a9ab1e26f94dd25282b.tar.gz
MFC r276577: MFV r276568:
Update file to 5.22.
Diffstat (limited to 'contrib/file/src/file.h')
-rw-r--r--contrib/file/src/file.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/contrib/file/src/file.h b/contrib/file/src/file.h
index 14fa836..01aa37a 100644
--- a/contrib/file/src/file.h
+++ b/contrib/file/src/file.h
@@ -27,7 +27,7 @@
*/
/*
* file.h - definitions for file(1) program
- * @(#)$File: file.h,v 1.161 2014/12/04 15:56:46 christos Exp $
+ * @(#)$File: file.h,v 1.164 2015/01/01 17:07:34 christos Exp $
*/
#ifndef __file_h__
@@ -234,6 +234,7 @@ struct magic {
(t) == FILE_LESTRING16 || \
(t) == FILE_REGEX || \
(t) == FILE_SEARCH || \
+ (t) == FILE_INDIRECT || \
(t) == FILE_NAME || \
(t) == FILE_USE)
@@ -346,6 +347,8 @@ struct magic {
#define STRING_IGNORE_CASE (STRING_IGNORE_LOWERCASE|STRING_IGNORE_UPPERCASE)
#define STRING_DEFAULT_RANGE 100
+#define INDIRECT_RELATIVE BIT(0)
+#define CHAR_INDIRECT_RELATIVE 'r'
/* list of magic entries */
struct mlist {
@@ -407,10 +410,12 @@ struct magic_set {
uint16_t name_max;
uint16_t elf_shnum_max;
uint16_t elf_phnum_max;
+ uint16_t elf_notes_max;
#define FILE_INDIR_MAX 15
#define FILE_NAME_MAX 30
#define FILE_ELF_SHNUM_MAX 32768
#define FILE_ELF_PHNUM_MAX 128
+#define FILE_ELF_NOTES_MAX 256
};
/* Type for Unicode characters */
@@ -476,6 +481,7 @@ protected int file_looks_utf8(const unsigned char *, size_t, unichar *,
size_t *);
protected size_t file_pstring_length_size(const struct magic *);
protected size_t file_pstring_get_length(const struct magic *, const char *);
+protected char * file_printable(char *, size_t, const char *);
#ifdef __EMX__
protected int file_os2_apptype(struct magic_set *, const char *, const void *,
size_t);
OpenPOWER on IntegriCloud