summaryrefslogtreecommitdiff
path: root/src/include/qmail.h
blob: ef68ddb5feb704cbfbb19c0449c606f295155a2f (plain)
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
#ifndef QMAIL_H
#define QMAIL_H

#include "buffer.h" // BUFFER_INSIZE = BUFFER_OUTSIZE = 8192

#define BUFSIZE_QMAIL 8192  // Memory page size
#define BUFSIZE_MESS  4096  
#define BUFSIZE_LINE  1024  // RFC 5322: 998 chars - why? - SMTP Line
#define BUFSIZE_AUTH   512
#define BUFSIZE_OUT    512
#define BUFSIZE_LOG    256
#define BUFSIZE_SMALL  128

struct qmail {
  int flagerr;
  unsigned long pid;
  int fdm;
  int fde;
  buffer ss;
  char buf[BUFSIZE_QMAIL];
} ;

extern int qmail_open(struct qmail *);
extern void qmail_put(struct qmail *,char *, int);
extern void qmail_puts(struct qmail *,char *);
extern void qmail_from(struct qmail *,char *);
extern void qmail_to(struct qmail *,char *);
extern void qmail_fail(struct qmail *);
extern char *qmail_close(struct qmail *);
extern unsigned long qmail_qp(struct qmail *);

#endif