3 #define aide_message(text) quickie_message("Citadel",NULL,AIDEROOM,text,0,NULL)
14 * Possible return codes from CtdlOutputMsg()
24 * Values of "headers_only" when calling message output routines
26 #define HEADERS_ALL 0 /* Headers and body */
27 #define HEADERS_ONLY 1 /* Headers only */
28 #define HEADERS_NONE 2 /* Body only */
29 #define HEADERS_FAST 3 /* Headers only with no MIME info */
33 int is_ma; /* Set to 1 if we are using this stuff */
34 int freeze; /* Freeze the replacement chain because we're
35 * digging through a subsection */
36 int did_print; /* One alternative has been displayed */
37 char chosen_part[128]; /* Which part of a m/a did we choose? */
41 struct repl { /* Info for replication checking */
42 char exclusive_id[SIZ];
47 /* Data structure returned by validate_recipients() */
56 char recp_internet[SIZ];
59 char display_recp[SIZ];
63 * This is a list of "harvested" email addresses that we might want to
64 * stick into someone's address book. But we defer this operaiton so
65 * it can be done asynchronously.
67 struct addresses_to_be_filed {
68 struct addresses_to_be_filed *next;
70 char *collected_addresses;
73 extern struct addresses_to_be_filed *atbf;
75 int alias (char *name);
77 void cmd_msgs (char *cmdbuf);
78 void cmd_isme (char *cmdbuf);
79 void help_subst (char *strbuf, char *source, char *dest);
80 void do_help_subst (char *buffer);
81 void memfmout (char *mptr, char subst, char *nl);
82 void output_mime_parts(char *);
83 void cmd_msg0 (char *cmdbuf);
84 void cmd_msg2 (char *cmdbuf);
85 void cmd_msg3 (char *cmdbuf);
86 void cmd_msg4 (char *cmdbuf);
87 void cmd_msgp (char *cmdbuf);
88 void cmd_opna (char *cmdbuf);
89 long send_message (struct CtdlMessage *);
90 void loadtroom (void);
91 long CtdlSubmitMsg(struct CtdlMessage *, struct recptypes *, char *);
92 void quickie_message (char *, char *, char *, char *, int, char *);
93 void cmd_ent0 (char *entargs);
94 void cmd_dele (char *delstr);
95 void cmd_move (char *args);
96 void GetMetaData(struct MetaData *, long);
97 void PutMetaData(struct MetaData *);
98 void AdjRefCount(long, int);
99 void simple_listing(long, void *);
100 int CtdlMsgCmp(struct CtdlMessage *msg, struct CtdlMessage *template);
101 int CtdlForEachMessage(int mode, long ref,
103 struct CtdlMessage *compare,
104 void (*CallBack) (long, void *),
106 int CtdlDeleteMessages(char *, long, char *, int);
107 void CtdlWriteObject(char *, char *, char *, struct ctdluser *,
108 int, int, unsigned int);
109 struct CtdlMessage *CtdlFetchMessage(long msgnum, int with_body);
110 void CtdlFreeMessage(struct CtdlMessage *msg);
111 void serialize_message(struct ser_ret *, struct CtdlMessage *);
112 int is_valid_message(struct CtdlMessage *);
113 void ReplicationChecks(struct CtdlMessage *);
114 int CtdlSaveMsgPointerInRoom(char *roomname, long msgid, int do_repl_check, struct CtdlMessage *msg);
115 char *CtdlReadMessageBody(char *terminator, size_t maxlen, char *exist, int crlf);
116 char *CtdlGetSysConfig(char *sysconfname);
117 void CtdlPutSysConfig(char *sysconfname, char *sysconfdata);
118 int CtdlOutputMsg(long msg_num, /* message number (local) to fetch */
119 int mode, /* how would you like that message? */
120 int headers_only, /* eschew the message body? */
121 int do_proto, /* do Citadel protocol responses? */
122 int crlf, /* 0=LF, 1=CRLF */
123 char *section /* output a message/rfc822 section */
125 int CtdlOutputPreLoadedMsg(struct CtdlMessage *,
126 int mode, /* how would you like that message? */
127 int headers_only, /* eschew the message body? */
128 int do_proto, /* do Citadel protocol responses? */
129 int crlf /* 0=LF, 1=CRLF */
131 int CtdlCopyMsgToRoom(long msgnum, char *dest);
132 int CtdlDoIHavePermissionToDeleteMessagesFromThisRoom(void);
133 int CtdlDoIHavePermissionToPostInThisRoom(char *errmsgbuf, size_t n);
136 /* values for which_set */
141 void CtdlSetSeen(long *target_msgnums, int num_target_msgnums,
142 int target_setting, int which_set,
143 struct ctdluser *which_user, struct ctdlroom *which_room);
144 void CtdlGetSeen(char *buf, int which_set);
146 struct recptypes *validate_recipients(char *recipients);
147 struct CtdlMessage *CtdlMakeMessage(
148 struct ctdluser *author, /* author's user structure */
149 char *recipient, /* NULL if it's not mail */
150 char *recp_cc, /* NULL if it's not mail */
151 char *room, /* room where it's going */
152 int type, /* see MES_ types in header file */
153 int format_type, /* variformat, plain text, MIME... */
154 char *fake_name, /* who we're masquerading as */
155 char *subject, /* Subject (optional) */
156 char *supplied_euid, /* ...or NULL if this is irrelevant */
157 char *preformatted_text /* ...or NULL to read text from client */
159 int CtdlCheckInternetMailPermission(struct ctdluser *who);
160 int CtdlIsMe(char *addr, int addr_buf_len);