From ab199b0c0cbcea6e8c28d879ee47edf2e6ff7263 Mon Sep 17 00:00:00 2001 From: simon987 Date: Sun, 24 May 2020 14:18:31 -0400 Subject: [PATCH] Remove arc_reset() function because seek() inside archive doesn't work --- src/parsing/parse.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/parsing/parse.c b/src/parsing/parse.c index ab33206..e061d8b 100644 --- a/src/parsing/parse.c +++ b/src/parsing/parse.c @@ -78,6 +78,12 @@ void parse(void *arg) { if (doc.mime == 0 && !ScanCtx.fast) { // Get mime type with libmagic + if (!job->vfile.is_fs_file) { + LOG_WARNING(job->filepath, + "Guessing mime type with libmagic inside archive files is not currently supported"); + return; + } + bytes_read = job->vfile.read(&job->vfile, buf, MAGIC_BUF_SIZE); if (bytes_read < 0) {