[Pkg-clamav-commits] [SCM] Debian repository for ClamAV branch, debian/unstable, updated. debian/0.95+dfsg-1-6156-g094ec9b

Török Edvin edwin at clamav.net
Sun Apr 4 01:20:20 UTC 2010


The following commit has been merged in the debian/unstable branch:
commit 039af772c8b0fda31d2a0e8fbb60344999bbe254
Author: Török Edvin <edwin at clamav.net>
Date:   Sat Feb 13 18:21:33 2010 +0200

    Don't fail if bytecode was skipped due to functionality level.

diff --git a/libclamav/bytecode.c b/libclamav/bytecode.c
index acfe1c8..989a808 100644
--- a/libclamav/bytecode.c
+++ b/libclamav/bytecode.c
@@ -434,7 +434,7 @@ static int parseHeader(struct cli_bc *bc, unsigned char *buffer, unsigned *linel
 	return CL_EMALFDB;
     }
     if (flevel != BC_FUNC_LEVEL) {
-	cli_dbgmsg("Skipping bytecode with functionality level: %u\n", flevel);
+	cli_dbgmsg("Skipping bytecode with functionality level: %u (current %u)\n", flevel, BC_FUNC_LEVEL);
 	return CL_BREAK;
     }
     /* Optimistic parsing, check for error only at the end.*/
diff --git a/libclamav/readdb.c b/libclamav/readdb.c
index 1f049dc..9d05f42 100644
--- a/libclamav/readdb.c
+++ b/libclamav/readdb.c
@@ -1409,6 +1409,11 @@ static int cli_loadcbc(FILE *fs, struct cl_engine *engine, unsigned int *signo,
 	cli_errmsg("Unable to load %s bytecode: %s\n", dbname, cl_strerror(rc));
 	return rc;
     }
+    if (bc->state == bc_skip) {
+	cli_bytecode_destroy(bc);
+	bcs->count--;
+	return CL_SUCCESS;
+    }
     bc->id = bcs->count;/* must set after _load, since load zeroes */
     sigs++;
     if (bc->kind == BC_LOGICAL || bc->lsig) {

-- 
Debian repository for ClamAV



More information about the Pkg-clamav-commits mailing list