git://git.exim.org
/
exim.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
ee74417
)
Fix log output including CR from clamd
author
Tom Kistner
<tom@duncanthrax.net>
Tue, 2 Aug 2005 18:24:14 +0000
(18:24 +0000)
committer
Tom Kistner
<tom@duncanthrax.net>
Tue, 2 Aug 2005 18:24:14 +0000
(18:24 +0000)
src/src/malware.c
patch
|
blob
|
history
diff --git
a/src/src/malware.c
b/src/src/malware.c
index ca9c3dfebd5390d46fa112e3155a35f531c03781..bdf3348d5b0d62b1d418dc2ffaa80630c12909ac 100644
(file)
--- a/
src/src/malware.c
+++ b/
src/src/malware.c
@@
-1,4
+1,4
@@
-/* $Cambridge: exim/src/src/malware.c,v 1.1
2 2005/08/01 14:41:25 ph10
Exp $ */
+/* $Cambridge: exim/src/src/malware.c,v 1.1
3 2005/08/02 18:24:14 tom
Exp $ */
/*************************************************
* Exim - an Internet mail transport agent *
/*************************************************
* Exim - an Internet mail transport agent *
@@
-1265,6
+1265,10
@@
int malware(uschar **listptr) {
return DEFER;
}
return DEFER;
}
+ /* strip newline at the end */
+ p = av_buffer + Ustrlen(av_buffer) - 1;
+ if( *p == '\n' ) *p = '\0';
+
/* colon in returned output? */
if((p = Ustrrchr(av_buffer,':')) == NULL) {
log_write(0, LOG_MAIN|LOG_PANIC,
/* colon in returned output? */
if((p = Ustrrchr(av_buffer,':')) == NULL) {
log_write(0, LOG_MAIN|LOG_PANIC,
@@
-1273,13
+1277,10
@@
int malware(uschar **listptr) {
return DEFER;
}
return DEFER;
}
- /* strip filename
strip CR at the end
*/
+ /* strip filename */
++p;
while (*p == ' ') ++p;
vname = p;
++p;
while (*p == ' ') ++p;
vname = p;
- p = vname + Ustrlen(vname) - 1;
- if( *p == '\n' ) *p = '\0';
-
if ((p = Ustrstr(vname, "FOUND"))!=NULL) {
*p=0;
for (--p;p>vname && *p<=32;p--) *p=0;
if ((p = Ustrstr(vname, "FOUND"))!=NULL) {
*p=0;
for (--p;p>vname && *p<=32;p--) *p=0;