Browse code

fix "clamdcan /" mode

git-svn: trunk@2697

Tomasz Kojm authored on 2007/02/11 02:45:54
Showing 2 changed files
... ...
@@ -1,3 +1,7 @@
1
+Sat Feb 10 18:44:52 CET 2007 (tk)
2
+---------------------------------
3
+  * clamdscan/client.c: fix "clamdcan /" mode, reported by Luca
4
+
1 5
 Sat Feb 10 17:47:36 CET 2007 (tk)
2 6
 ---------------------------------
3 7
   * configure.in: fix bb#267, patch from Edwin
... ...
@@ -466,7 +466,7 @@ int client(const struct optstruct *opt, int *infected)
466 466
 		perror(fullpath);
467 467
 		errors++;
468 468
 	    } else {
469
-		if(strlen(fullpath) < 2 || (fullpath[0] != '/' && fullpath[0] != '\\' && fullpath[1] != ':')) {
469
+		if(strcmp(fullpath, "/") && (strlen(fullpath) < 2 || (fullpath[0] != '/' && fullpath[0] != '\\' && fullpath[1] != ':'))) {
470 470
 		    fullpath = abpath(thefilename);
471 471
 		    free(thefilename);
472 472