xxfi_close.html revision 132943
190792Sgshapiro<html>
290792Sgshapiro<head><title>xxfi_close</title></head>
390792Sgshapiro<body>
4132943Sgshapiro<!--
5132943Sgshapiro$Id: xxfi_close.html,v 1.10 2004/06/16 22:41:36 ca Exp $
6132943Sgshapiro-->
790792Sgshapiro<h1>xxfi_close</h1>
890792Sgshapiro
990792Sgshapiro<table border="0" cellspacing=4 cellpadding=4>
1090792Sgshapiro<!---------- Synopsis ----------->
1190792Sgshapiro<tr><th valign="top" align=left width=150>SYNOPSIS</th><td>
1290792Sgshapiro<pre>
1390792Sgshapiro#include &lt;libmilter/mfapi.h&gt;
1490792Sgshapirosfsistat (*xxfi_close)(
1590792Sgshapiro	SMFICTX * ctx
1690792Sgshapiro);
1790792Sgshapiro</pre>
1890792SgshapiroThe current connection is being closed.
1990792Sgshapiro</td></tr>
2090792Sgshapiro
2190792Sgshapiro<!----------- Description ---------->
2290792Sgshapiro<tr><th valign="top" align=left>DESCRIPTION</th><td>
2390792Sgshapiro<table border="1" cellspacing=1 cellpadding=4>
2490792Sgshapiro<tr align="left" valign=top>
2590792Sgshapiro<th width="80">Called When</th>
2690792Sgshapiro<td>xxfi_close is always called once at the end of each connection.</td>
2790792Sgshapiro</tr>
2890792Sgshapiro<tr align="left" valign=top>
2990792Sgshapiro<th>Default Behavior</th>
3090792Sgshapiro<td>Do nothing; return SMFIS_CONTINUE.</td>
3190792Sgshapiro</tr>
3290792Sgshapiro</table>
3390792Sgshapiro
3490792Sgshapiro<!----------- Arguments ---------->
3590792Sgshapiro<tr><th valign="top" align=left>ARGUMENTS</th><td>
3690792Sgshapiro    <table border="1" cellspacing=0>
3790792Sgshapiro    <tr bgcolor="#dddddd"><th>Argument</th><th>Description</th></tr>
3890792Sgshapiro    <tr valign="top"><td>ctx</td>
3990792Sgshapiro	<td>Opaque context structure.
4090792Sgshapiro	</td></tr>
4190792Sgshapiro    </table>
4290792Sgshapiro</td></tr>
4390792Sgshapiro
4490792Sgshapiro<!----------- Notes ---------->
4590792Sgshapiro<tr>
4690792Sgshapiro<th valign="top" align=left>NOTES</th> 
4790792Sgshapiro<td>
4890792Sgshapiro<ul>
49132943Sgshapiro<li>xxfi_close may be called "out-of-order", i.e. before even the
50132943Sgshapiroxxfi_connect is called.
51132943SgshapiroAfter a connection is established by the MTA to the filter,
52132943Sgshapiroif the MTA decides this connection's traffic will be discarded
53132943Sgshapiro(e.g. via an access_db result), no data will be passed to the
54132943Sgshapirofilter from the MTA until the client closes down.
55132943SgshapiroAt that time, xxfi_close is called.
56132943SgshapiroIt can therefore be the only callback ever used for a given connection,
57132943Sgshapiroand developers should anticipate this possibility when crafting their
58132943Sgshapiroxxfi_close code.
59132943SgshapiroIn particular, it is incorrect to assume the private context pointer
60132943Sgshapirowill be something other than NULL in this callback.
6190792Sgshapiro<li>xxfi_close is called on close even if the previous mail
6290792Sgshapirotransaction was aborted.  
6390792Sgshapiro<li>xxfi_close is responsible for freeing any resources allocated on a
6490792Sgshapiroper-connection basis.
6590792Sgshapiro<li>Since the connection is already closing, the return value is
6690792Sgshapirocurrently ignored.
6790792Sgshapiro</ul>
6890792Sgshapiro</td>
6990792Sgshapiro</tr>
7090792Sgshapiro</table>
7190792Sgshapiro
7290792Sgshapiro<hr size="1">
7390792Sgshapiro<font size="-1">
74132943SgshapiroCopyright (c) 2000, 2003, 2004 Sendmail, Inc. and its suppliers.
7590792SgshapiroAll rights reserved.
7690792Sgshapiro<br>
7790792SgshapiroBy using this file, you agree to the terms and conditions set
78112810Sgshapiroforth in the LICENSE.
7990792Sgshapiro</font>
8090792Sgshapiro</body>
8190792Sgshapiro</html>
82