Cygwin 1.5.6-1 and 20040126 : SIGSEGV in random() ???

Nicolas Lehuen
Wed Jan 28 10:17:00 GMT 2004


I'm trying to run the latest snapshot of clamav ( )
under Cygwin 1.5.6-1. I compiled and ran the virus DB update (freshclam)
nicely. However each time I want to run the scanner (clamscan) I get a
segmentation fault at random times ; sometimes it will perform a full scan,
sometime it will stop after a few files, sometimes it won't even start. I
ran clamscan under gdb and this is what I got :

$ gdb clamscan
GNU gdb 2003-09-20-cvs (cygwin-special)
Copyright 2003 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i686-pc-cygwin"...
(gdb) run
Starting program: /usr/local/bin/clamscan.exe

Program received signal SIGSEGV, Segmentation fault.
0x610ab285 in random () from /usr/bin/cygwin1.dll
(gdb) where
#0  0x610ab285 in random () from /usr/bin/cygwin1.dll
#1  0x610ab057 in random () from /usr/bin/cygwin1.dll
#2  0x61054e66 in localtime_r () from /usr/bin/cygwin1.dll
#3  0x61086431 in cygwin1!aclcheck () from /usr/bin/cygwin1.dll
#4  0x0041ae72 in cli_cvdload (fd=0x10032504, root=0x22ed0c,
    at cvd.c:370
#5  0x0040eb95 in cl_loaddb (
    filename=0x100301f0 "/usr/local/share/clamav/daily.cvd", root=0x22ed0c,
    virnum=0x41e1a0) at readdb.c:103
#6  0x0040f0d2 in cl_loaddbdir (dirname=0x40ee95 "/usr/local/share/clamav",
    root=0x22ed0c, virnum=0x41e1a0) at readdb.c:221
#7  0x0040520a in scanmanager (opt=0x41e1a0) at manager.c:92
#8  0x0022ed0c in ?? ()
#9  0x0041e1a0 in bell ()

I guess this explain the random occurence of the SIGSEGVs... Is there any
way this could be due to a bad usage of random() by clamav ? Or is it a
problem with this version of cygwin ? I've tried with the latest snapshot
available (20040126) with the same result. Someone already built an older
version of clamav under an older version of cygwin, I tried it and it worked
: . However I'd like to run with
the latest version...


Unsubscribe info:
Problem reports:

More information about the Cygwin mailing list