File: imap_sendmail.h

package info (click to toggle)
php3 3%3A3.0.18-0potato1.1
  • links: PTS
  • area: main
  • in suites: potato
  • size: 17,736 kB
  • ctags: 11,198
  • sloc: ansic: 108,120; sh: 2,512; php: 2,024; yacc: 1,887; makefile: 1,038; perl: 537; pascal: 238; awk: 90; cpp: 28; sql: 11
file content (43 lines) | stat: -rw-r--r-- 1,339 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
#if !defined(imap_sendmail_h)		// Sentry, use file only if it's not already included.
#define imap_sendmail_h
#include <windows.h>

#define HOST_NAME_LEN	256
#define MAX_APPNAME_LENGHT 100
#define  MAX_ERROR_INDEX		17
#define  MIN_ERROR_INDEX		0
#define  MAIL_BUFFER_SIZE		(1024*4)	// 4k buffer
// Return values
#define	SUCCESS 0
#define	FAILED_TO_PARSE_ARGUMENTS 1
#define	FAILED_TO_OPEN_MAILFILE 2
#define	FAILED_TO_START_SOCKETS 3
#define	FAILED_TO_RESOLVE_HOST 4
#define	FAILED_TO_OBTAIN_SOCKET_HANDLE 5
#define	FAILED_TO_CONNECT 6
#define	FAILED_TO_SEND 7
#define	FAILED_TO_RECEIVE 8
#define	SMTP_SERVER_ERROR 9
#define	FAILED_TO_GET_HOSTNAME 10
#define	OUT_OF_MEMORY 11
#define	UNKNOWN_ERROR 12
#define	BAD_MSG_CONTENTS 13
#define	BAD_MSG_SUBJECT 14
#define	BAD_MSG_DESTINATION 15
#define	BAD_MSG_RPATH 16
#define	BAD_MAIL_HOST 17
#define BAD_MSG_FILE 18

int imap_TSendMail(char *host, int *error,
			  char *headers, char *Subject, char *mailTo, char *data, char *mailCc, char *mailBcc, char *mailRPath);
void TSMClose(void);
int imap_SendText(char *RPath, char *Subject, char *mailTo, char *data, char *headers, char *mailCc, char *mailBcc);
char *GetSMErrorText(int index);

int MailConnect();
int imap_PostHeader(char *, char *, char *, char *, char *);
int Post(LPCSTR);
int Ack();
unsigned long GetAddr(LPSTR szHost);

#endif