summaryrefslogtreecommitdiffstats
path: root/contrib/file/src/ascmagic.c
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/file/src/ascmagic.c')
-rw-r--r--contrib/file/src/ascmagic.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/contrib/file/src/ascmagic.c b/contrib/file/src/ascmagic.c
index b9ab789..9e0f663 100644
--- a/contrib/file/src/ascmagic.c
+++ b/contrib/file/src/ascmagic.c
@@ -35,7 +35,7 @@
#include "file.h"
#ifndef lint
-FILE_RCSID("@(#)$File: ascmagic.c,v 1.94 2016/03/31 17:51:12 christos Exp $")
+FILE_RCSID("@(#)$File: ascmagic.c,v 1.92 2015/04/09 20:01:41 christos Exp $")
#endif /* lint */
#include "magic.h"
@@ -147,7 +147,7 @@ file_ascmagic_with_encoding(struct magic_set *ms, const unsigned char *buf,
== NULL)
goto done;
if ((rv = file_softmagic(ms, utf8_buf,
- (size_t)(utf8_end - utf8_buf), NULL, NULL,
+ (size_t)(utf8_end - utf8_buf), 0, NULL,
TEXTTEST, text)) == 0)
rv = -1;
}
@@ -183,10 +183,10 @@ file_ascmagic_with_encoding(struct magic_set *ms, const unsigned char *buf,
}
/* Beware, if the data has been truncated, the final CR could have
- been followed by a LF. If we have ms->bytes_max bytes, it indicates
+ been followed by a LF. If we have HOWMANY bytes, it indicates
that the data might have been truncated, probably even before
this function was called. */
- if (seen_cr && nbytes < ms->bytes_max)
+ if (seen_cr && nbytes < HOWMANY)
n_cr++;
if (strcmp(type, "binary") == 0) {
OpenPOWER on IntegriCloud