Browse code

Bug 520

git-svn: trunk@3062

Nigel Horne authored on 2007/05/25 19:10:30
Showing 2 changed files
... ...
@@ -1,3 +1,7 @@
1
+Fri May 25 10:33:19 BST 2007 (njh)
2
+----------------------------------
3
+  * libclamav/blob.c:	Bug 520
4
+
1 5
 Wed May 23 15:30:32 CEST 2007 (tk)
2 6
 ----------------------------------
3 7
   * libclamav: DCONF support for NSIS
... ...
@@ -242,7 +242,7 @@ blobGetData(const blob *b)
242 242
 
243 243
 	if(b->len == 0)
244 244
 		return NULL;
245
-	return(b->data);
245
+	return b->data;
246 246
 }
247 247
 
248 248
 size_t
... ...
@@ -251,7 +251,7 @@ blobGetDataSize(const blob *b)
251 251
 	assert(b != NULL);
252 252
 	assert(b->magic == BLOBCLASS);
253 253
 
254
-	return(b->len);
254
+	return b->len;
255 255
 }
256 256
 
257 257
 void
... ...
@@ -574,9 +574,15 @@ sanitiseName(char *name)
574 574
 #ifdef	C_DARWIN
575 575
 		*name &= '\177';
576 576
 #endif
577
-	    /* Also check for tab - "Heinz Martin" <Martin@hemag.ch> */
578
-#if	defined(MSDOS) || defined(C_CYGWIN) || defined(C_WINDOWS) || defined(C_OS2)
577
+		/* Also check for tab - "Heinz Martin" <Martin@hemag.ch> */
578
+#if	defined(MSDOS) || defined(C_OS2)
579
+		/*
580
+		 * Don't take it from this that ClamAV supports DOS, it doesn't
581
+		 * I don't know if spaces are legal in OS/2.
582
+		 */
579 583
 		if(strchr("%/*?<>|\\\"+=,;:\t ~", *name))
584
+#elif	defined(C_CYGWIN) || defined(C_WINDOWS)
585
+		if(strchr("%/*?<>|\\\"+=,;:\t~", *name))
580 586
 #else
581 587
 		if(*name == '/')
582 588
 #endif