summaryrefslogtreecommitdiff
path: root/usr/src
diff options
context:
space:
mode:
Diffstat (limited to 'usr/src')
-rw-r--r--usr/src/cmd/sendmail/libmilter/engine.c7
-rw-r--r--usr/src/cmd/sendmail/libmilter/listener.c8
-rw-r--r--usr/src/cmd/sendmail/libmilter/main.c9
-rw-r--r--usr/src/cmd/sendmail/libmilter/smfi.c6
4 files changed, 18 insertions, 12 deletions
diff --git a/usr/src/cmd/sendmail/libmilter/engine.c b/usr/src/cmd/sendmail/libmilter/engine.c
index 06579d613b..9e32ccbc82 100644
--- a/usr/src/cmd/sendmail/libmilter/engine.c
+++ b/usr/src/cmd/sendmail/libmilter/engine.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1999-2004, 2006 Sendmail, Inc. and its suppliers.
+ * Copyright (c) 1999-2004, 2006, 2007 Sendmail, Inc. and its suppliers.
* All rights reserved.
*
* By using this file, you agree to the terms and conditions set
@@ -11,7 +11,7 @@
#pragma ident "%Z%%M% %I% %E% SMI"
#include <sm/gen.h>
-SM_RCSID("@(#)$Id: engine.c,v 8.157 2007/03/26 18:10:04 ca Exp $")
+SM_RCSID("@(#)$Id: engine.c,v 8.159 2007/04/23 22:22:50 ca Exp $")
#include "libmilter.h"
@@ -857,6 +857,7 @@ st_optionneg(g)
;
if (g->a_ctx->ctx_smfi != NULL &&
+ g->a_ctx->ctx_smfi->xxfi_version > 4 &&
(fi_negotiate = g->a_ctx->ctx_smfi->xxfi_negotiate) != NULL)
{
int r;
@@ -1179,6 +1180,7 @@ st_data(g)
if (g == NULL)
return _SMFIS_ABORT;
if (g->a_ctx->ctx_smfi != NULL &&
+ g->a_ctx->ctx_smfi->xxfi_version > 3 &&
(fi_data = g->a_ctx->ctx_smfi->xxfi_data) != NULL)
return (*fi_data)(g->a_ctx);
return SMFIS_CONTINUE;
@@ -1312,6 +1314,7 @@ st_unknown(g)
if (g == NULL)
return _SMFIS_ABORT;
if (g->a_ctx->ctx_smfi != NULL &&
+ g->a_ctx->ctx_smfi->xxfi_version > 2 &&
(fi_unknown = g->a_ctx->ctx_smfi->xxfi_unknown) != NULL)
return (*fi_unknown)(g->a_ctx, (const char *) g->a_buf);
return SMFIS_CONTINUE;
diff --git a/usr/src/cmd/sendmail/libmilter/listener.c b/usr/src/cmd/sendmail/libmilter/listener.c
index 9c34029450..e9f62f2e7b 100644
--- a/usr/src/cmd/sendmail/libmilter/listener.c
+++ b/usr/src/cmd/sendmail/libmilter/listener.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1999-2006 Sendmail, Inc. and its suppliers.
+ * Copyright (c) 1999-2007 Sendmail, Inc. and its suppliers.
* All rights reserved.
*
* By using this file, you agree to the terms and conditions set
@@ -11,7 +11,7 @@
#pragma ident "%Z%%M% %I% %E% SMI"
#include <sm/gen.h>
-SM_RCSID("@(#)$Id: listener.c,v 8.122 2006/11/02 17:54:44 ca Exp $")
+SM_RCSID("@(#)$Id: listener.c,v 8.124 2007/04/23 22:22:50 ca Exp $")
/*
** listener.c -- threaded network listener
@@ -929,9 +929,9 @@ mi_listener(conn, dbg, smfi, timeout, backlog)
ctx->ctx_pflags |= SMFIP_NOEOH;
if (smfi->xxfi_body == NULL)
ctx->ctx_pflags |= SMFIP_NOBODY;
- if (smfi->xxfi_data == NULL)
+ if (smfi->xxfi_version <= 3 || smfi->xxfi_data == NULL)
ctx->ctx_pflags |= SMFIP_NODATA;
- if (smfi->xxfi_unknown == NULL)
+ if (smfi->xxfi_version <= 2 || smfi->xxfi_unknown == NULL)
ctx->ctx_pflags |= SMFIP_NOUNKNOWN;
#if _FFR_WORKERS_POOL
diff --git a/usr/src/cmd/sendmail/libmilter/main.c b/usr/src/cmd/sendmail/libmilter/main.c
index 10dc778870..b8609cd785 100644
--- a/usr/src/cmd/sendmail/libmilter/main.c
+++ b/usr/src/cmd/sendmail/libmilter/main.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1999-2003, 2006 Sendmail, Inc. and its suppliers.
+ * Copyright (c) 1999-2003, 2006, 2007 Sendmail, Inc. and its suppliers.
* All rights reserved.
*
* By using this file, you agree to the terms and conditions set
@@ -11,7 +11,7 @@
#pragma ident "%Z%%M% %I% %E% SMI"
#include <sm/gen.h>
-SM_RCSID("@(#)$Id: main.c,v 8.81 2006/11/02 18:31:43 ca Exp $")
+SM_RCSID("@(#)$Id: main.c,v 8.83 2007/04/23 22:22:50 ca Exp $")
#define _DEFINE 1
#include "libmilter.h"
@@ -54,7 +54,10 @@ smfi_register(smfilter)
(void) sm_strlcpy(smfi->xxfi_name, smfilter.xxfi_name, len);
/* compare milter version with hard coded version */
- if (smfi->xxfi_version != SMFI_VERSION)
+ if (smfi->xxfi_version != SMFI_VERSION &&
+ smfi->xxfi_version != 2 &&
+ smfi->xxfi_version != 3 &&
+ smfi->xxfi_version != 4)
{
/* hard failure for now! */
smi_log(SMI_LOG_ERR,
diff --git a/usr/src/cmd/sendmail/libmilter/smfi.c b/usr/src/cmd/sendmail/libmilter/smfi.c
index 620ec3a575..af034481ee 100644
--- a/usr/src/cmd/sendmail/libmilter/smfi.c
+++ b/usr/src/cmd/sendmail/libmilter/smfi.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1999-2006 Sendmail, Inc. and its suppliers.
+ * Copyright (c) 1999-2007 Sendmail, Inc. and its suppliers.
* All rights reserved.
*
* By using this file, you agree to the terms and conditions set
@@ -11,7 +11,7 @@
#pragma ident "%Z%%M% %I% %E% SMI"
#include <sm/gen.h>
-SM_RCSID("@(#)$Id: smfi.c,v 8.82 2007/01/20 06:37:19 ca Exp $")
+SM_RCSID("@(#)$Id: smfi.c,v 8.83 2007/04/23 16:44:39 ca Exp $")
#include <sm/varargs.h>
#include "libmilter.h"
@@ -886,6 +886,6 @@ smfi_version(major, minor, patchlevel)
if (minor != NULL)
*minor = SM_LM_VRS_MINOR(SMFI_VERSION);
if (patchlevel != NULL)
- *patchlevel = SM_LM_VRS_MINOR(SMFI_VERSION);
+ *patchlevel = SM_LM_VRS_PLVL(SMFI_VERSION);
return MI_SUCCESS;
}