1 /* $NetBSD: post_mail.h,v 1.1.1.1 2009/06/23 10:08:47 tron Exp $ */ 2 3 #ifndef _POST_MAIL_H_INCLUDED_ 4 #define _POST_MAIL_H_INCLUDED_ 5 6 /*++ 7 /* NAME 8 /* post_mail 3h 9 /* SUMMARY 10 /* convenient mail posting interface 11 /* SYNOPSIS 12 /* #include <post_mail.h> 13 /* DESCRIPTION 14 /* .nf 15 16 /* 17 * Utility library. 18 */ 19 #include <vstream.h> 20 #include <vstring.h> 21 22 /* 23 * Global library. 24 */ 25 #include <cleanup_user.h> 26 #include <int_filt.h> 27 28 /* 29 * External interface. 30 */ 31 typedef void (*POST_MAIL_NOTIFY)(VSTREAM *, void *); 32 extern VSTREAM *post_mail_fopen(const char *, const char *, int, int, VSTRING *); 33 extern VSTREAM *post_mail_fopen_nowait(const char *, const char *, int, int, VSTRING *); 34 extern void post_mail_fopen_async(const char *, const char *, int, int, VSTRING *, POST_MAIL_NOTIFY, void *); 35 extern int PRINTFLIKE(2, 3) post_mail_fprintf(VSTREAM *, const char *,...); 36 extern int post_mail_fputs(VSTREAM *, const char *); 37 extern int post_mail_buffer(VSTREAM *, const char *, int); 38 extern int post_mail_fclose(VSTREAM *); 39 40 #define POST_MAIL_BUFFER(v, b) \ 41 post_mail_buffer((v), vstring_str(b), VSTRING_LEN(b)) 42 43 /* LICENSE 44 /* .ad 45 /* .fi 46 /* The Secure Mailer license must be distributed with this software. 47 /* AUTHOR(S) 48 /* Wietse Venema 49 /* IBM T.J. Watson Research 50 /* P.O. Box 704 51 /* Yorktown Heights, NY 10598, USA 52 /*--*/ 53 54 #endif 55