[Pkg-clamav-commits] [SCM] Debian repository for ClamAV branch, debian/unstable, updated. debian/0.95+dfsg-1-6156-g094ec9b
aCaB
acab at clamav.net
Sun Apr 4 01:23:07 UTC 2010
The following commit has been merged in the debian/unstable branch:
commit 89e12eec819ab3952cc4f53953736f825ac445d1
Author: aCaB <acab at clamav.net>
Date: Fri Mar 19 02:46:01 2010 +0100
win32: more safe_opens
diff --git a/clamdscan/proto.c b/clamdscan/proto.c
index 0867daa..20f1689 100644
--- a/clamdscan/proto.c
+++ b/clamdscan/proto.c
@@ -166,7 +166,7 @@ static int send_stream(int sockd, const char *filename) {
unsigned long int todo = maxstream;
if(filename) {
- if((fd = open(filename, O_RDONLY | O_BINARY))<0) {
+ if((fd = safe_open(filename, O_RDONLY | O_BINARY))<0) {
logg("~%s: Access denied. ERROR\n", filename);
return 0;
}
diff --git a/libclamav/scanners.c b/libclamav/scanners.c
index f36148b..9124f9d 100644
--- a/libclamav/scanners.c
+++ b/libclamav/scanners.c
@@ -2380,7 +2380,7 @@ int cl_scanfile(const char *filename, const char **virname, unsigned long int *s
{
int fd, ret;
- if((fd = open(filename, O_RDONLY|O_BINARY)) == -1)
+ if((fd = safe_open(filename, O_RDONLY|O_BINARY)) == -1)
return CL_EOPEN;
ret = cl_scandesc(fd, virname, scanned, engine, scanoptions);
--
Debian repository for ClamAV
More information about the Pkg-clamav-commits
mailing list