git-svn: trunk@2325
Nigel Horne authored on 2006/09/28 04:16:11... | ... |
@@ -1,3 +1,7 @@ |
1 |
+Wed Sep 27 20:15:20 BST 2006 (njh) |
|
2 |
+---------------------------------- |
|
3 |
+ * libclamav/regex_list.c: Fix segfault on Solaris when running --debug |
|
4 |
+ |
|
1 | 5 |
Wed Sep 27 17:37:42 BST 2006 (njh) |
2 | 6 |
---------------------------------- |
3 | 7 |
* clamav-milter: --report sometimes failed |
... | ... |
@@ -19,6 +19,9 @@ |
19 | 19 |
* MA 02110-1301, USA. |
20 | 20 |
* |
21 | 21 |
* $Log: regex_list.c,v $ |
22 |
+ * Revision 1.6 2006/09/27 19:14:49 njh |
|
23 |
+ * Fix segfault on Solaris |
|
24 |
+ * |
|
22 | 25 |
* Revision 1.5 2006/09/26 18:55:36 njh |
23 | 26 |
* Fixed portability issues |
24 | 27 |
* |
... | ... |
@@ -250,10 +253,10 @@ int regex_list_match(struct regex_matcher* matcher,const char* real_url,const ch |
250 | 250 |
strncpy(buffer,real_url,real_len); |
251 | 251 |
buffer[real_len]=hostOnly ? '\0' : ' '; |
252 | 252 |
if(!hostOnly) { |
253 |
- strncpy(buffer+real_len+1,display_url,display_len); |
|
254 |
- buffer[buffer_len]=0; |
|
253 |
+ strncpy(buffer+real_len+1,display_url,display_len); |
|
254 |
+ buffer[buffer_len]=0; |
|
255 | 255 |
} |
256 |
- cli_dbgmsg("Looking up in regex_list: %s\n"); |
|
256 |
+ cli_dbgmsg("Looking up in regex_list: %s\n", buffer); |
|
257 | 257 |
|
258 | 258 |
rc = cli_ac_scanbuff(buffer,buffer_len,info,hostOnly ? matcher->root_hosts : matcher->root_urls,&partcnt,0,0,&partoff,0,-1,NULL); |
259 | 259 |
if(!rc && !hostOnly) |