Article View: linux.debian.bugs.dist
Article #7372Bug#740059: [Pkg-clamav-devel] Bug#740059: clamav: LibClamAV Error: CRITICAL: fmap() failed
From: Sebastian Andrzej Siewior
Date: Thu, 03 Dec 2026 20:10
Date: Thu, 03 Dec 2026 20:10
29 lines
3557 bytes
3557 bytes
On 2026-12-01 21:11:59 [+0200], Edmund Lodewijks wrote:
> Looking at the 1.4.7 tarball, libclamav/fmap.c:393-416):
>
> if (use_aging) {
> if ((m->data = (fmap_t *)mmap(NULL, mapsz,
> PROT_READ | PROT_WRITE, MAP_PRIVATE | ANONYMOUS_MAP,
> -1, 0)) == MAP_FAILED) {
> m->data = NULL;
> }
> ...
> }
> if (!use_aging) {
> m->data = (fmap_t *)cli_max_malloc(mapsz);
> }
>
> Doesn't this do sort of what you want? Yet, it still wouldn't work on a
> 32-bit system? That would mean armhf, which is an officially supported
> Debian architecture. Not sure if this bug can be closed, since the issue is
> probably not resolved; but it also doesn't look like it will be?
Maybe close it. I remember the windows implementation read the file
chunks while linux mapped the whole thing. That would be ideal so you
would map the whole thing and keep it. If you scan large files, I can't
imagine having 10G in RAM sitting around is a good thing.
Anyway. I would suggest to close it and if someone has this problem I
would suggest to look at this again and loop in upstream.
Sebastian
Technical Details
Message-ID:
<O6lhU-fNKA-7@gated-at.bofh.it>Path:
mbox-mo1.pugleaf.net!news-fra.pugleaf.net!feed-eu-txt.newsdeef.eu!feed-eu-ch.newsdeef.eu!srl.newsdeef.eu!newsfeed.bofh.team!news.samoylyk.net!gothmog.csi.it!bofh.it!news.nic.it!robomodReferences:
<mPnhi-6RD-31@gated-at.bofh.it> <mUXk5-dm-7@gated-at.bofh.it> <mW2B3-7zu-5@gated-at.bofh.it> <mW2B3-7zu-3@gated-at.bofh.it> <n5PVU-1sG-9@gated-at.bofh.it> <n5PVU-1sG-9@gated-at.bofh.it> <mPnhi-6RD-31@gated-at.bofh.it> <O5Byp-fotD-5@gated-at.bofh.it> <mPnhi-6RD-31@gated-at.bofh.it> <O5Byp-fotD-5@gated-at.bofh.it>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-fra.pugleaf.net!feed-eu-txt.newsdeef.eu!feed-eu-ch.newsdeef.eu!srl.newsdeef.eu!newsfeed.bofh.team!news.samoylyk.net!gothmog.csi.it!bofh.it!news.nic.it!robomod From: Sebastian Andrzej Siewior <sebastian@breakpoint.cc> Newsgroups: linux.debian.bugs.dist Subject: Bug#740059: [Pkg-clamav-devel] Bug#740059: clamav: LibClamAV Error: CRITICAL: fmap() failed Date: Thu, 03 Dec 2026 21:10:02 +0100 Message-ID: <O6lhU-fNKA-7@gated-at.bofh.it> References: <mPnhi-6RD-31@gated-at.bofh.it> <mUXk5-dm-7@gated-at.bofh.it> <mW2B3-7zu-5@gated-at.bofh.it> <mW2B3-7zu-3@gated-at.bofh.it> <n5PVU-1sG-9@gated-at.bofh.it> <n5PVU-1sG-9@gated-at.bofh.it> <mPnhi-6RD-31@gated-at.bofh.it> <O5Byp-fotD-5@gated-at.bofh.it> <mPnhi-6RD-31@gated-at.bofh.it> <O5Byp-fotD-5@gated-at.bofh.it> X-Original-To: Edmund Lodewijks <edmund@proteamail.com>, 740059@bugs.debian.org X-Mailbox-Line: From debian-bugs-dist-request@lists.debian.org Thu Dec 3 20:01:06 2026 Old-Return-Path: <debbugs@buxtehude.debian.org> X-Spam-Flag: NO X-Spam-Score: -1.451 Reply-To: Sebastian Andrzej Siewior <sebastian@breakpoint.cc>, 740059@bugs.debian.org Resent-To: debian-bugs-dist@lists.debian.org Resent-Cc: pkg-clamav-devel@lists.alioth.debian.org X-Debian-Pr-Message: followup 740059 X-Debian-Pr-Package: clamav X-Debian-Pr-Keywords: upstream X-Debian-Pr-Source: clamav MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline X-Debian-Message: from BTS X-Mailing-List: <debian-bugs-dist@lists.debian.org> archive/latest/2006813 List-ID: <debian-bugs-dist.lists.debian.org> List-URL: <https://lists.debian.org/debian-bugs-dist/> Approved: robomod@news.nic.it Lines: 29 Organization: linux.* mail to news gateway Sender: robomod@news.nic.it X-Original-Date: Thu, 3 Dec 2026 20:58:59 +0100 X-Original-Message-ID: <20261203195859.lrfdl9RS@breakpoint.cc> X-Original-References: <20140225100856.19679.57014.reportbug@STNdom> <20140312191938.GA7669@breakpoint.cc> <20140316001638.69111431@STNdom> <20140315193701.GA4262@breakpoint.cc> <20140411200707.GA13764@breakpoint.cc> <20140411200707.GA13764@breakpoint.cc> <20140225100856.19679.57014.reportbug@STNdom> <4b8d3fc9-db52-452c-87d1-a2f28ceb390c@proteamail.com> <20140225100856.19679.57014.reportbug@STNdom> <4b8d3fc9-db52-452c-87d1-a2f28ceb390c@proteamail.com>