git-svn: trunk@2488
aCaB authored on 2006/11/06 03:16:56... | ... |
@@ -1,3 +1,10 @@ |
1 |
+Sun Nov 5 19:11:28 CET 2006 (acab) |
|
2 |
+----------------------------------- |
|
3 |
+ * libclamav/regex_list.c: apply patch from Edvin to: |
|
4 |
+ fix jump on uninitialized variable |
|
5 |
+ fix improprer string length calculation |
|
6 |
+ - closes bug 52 - |
|
7 |
+ |
|
1 | 8 |
Sun Nov 5 15:08:09 CET 2006 (tk) |
2 | 9 |
--------------------------------- |
3 | 10 |
* libclamav/pe.c: don't report I/O error when EP is near (less than 200 bytes) |
... | ... |
@@ -19,6 +19,9 @@ |
19 | 19 |
* MA 02110-1301, USA. |
20 | 20 |
* |
21 | 21 |
* $Log: regex_list.c,v $ |
22 |
+ * Revision 1.14 2006/11/05 18:16:56 acab |
|
23 |
+ * Patch for bug 52 from Edvin |
|
24 |
+ * |
|
22 | 25 |
* Revision 1.13 2006/10/30 17:53:03 tkojm |
23 | 26 |
* apply patch from Edvin reported by Luca |
24 | 27 |
* |
... | ... |
@@ -344,10 +347,10 @@ int regex_list_match(struct regex_matcher* matcher,const char* real_url,const ch |
344 | 344 |
{ |
345 | 345 |
size_t real_len = strlen(real_url); |
346 | 346 |
size_t display_len = strlen(display_url); |
347 |
- size_t buffer_len = hostOnly ? real_len : real_len + display_len + 1; |
|
347 |
+ size_t buffer_len = (hostOnly && !is_whitelist) ? real_len : real_len + display_len + 1; |
|
348 | 348 |
char* buffer = cli_malloc(buffer_len+1); |
349 | 349 |
size_t i; |
350 |
- int partcnt,rc; |
|
350 |
+ int partcnt,rc = 0; |
|
351 | 351 |
unsigned long int partoff; |
352 | 352 |
|
353 | 353 |
if(!buffer) |