projects
/
apps
/
madmutt.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
not having wide chars is soooo 90, please, I *really* don't care with
[apps/madmutt.git]
/
sendlib.c
diff --git
a/sendlib.c
b/sendlib.c
index
02d0ee0
..
a5ba72c
100644
(file)
--- a/
sendlib.c
+++ b/
sendlib.c
@@
-13,18
+13,34
@@
# include "config.h"
#endif
# include "config.h"
#endif
+#include <string.h>
+#include <stdlib.h>
+#include <unistd.h>
+#include <errno.h>
+#include <ctype.h>
+#include <sys/stat.h>
+#include <signal.h>
+#include <sys/wait.h>
+#include <fcntl.h>
+#include <sys/utsname.h>
+
#include <lib-lib/mem.h>
#include <lib-lib/ascii.h>
#include <lib-lib/str.h>
#include <lib-lib/macros.h>
#include <lib-lib/file.h>
#include <lib-lib/mem.h>
#include <lib-lib/ascii.h>
#include <lib-lib/str.h>
#include <lib-lib/macros.h>
#include <lib-lib/file.h>
+#include <lib-lib/debug.h>
+
+#include <lib-sys/exit.h>
+#include <lib-sys/mutt_signal.h>
#include <lib-mime/mime.h>
#include <lib-mime/mime.h>
+#include <lib-ui/curses.h>
+
#include "mutt.h"
#include "handler.h"
#include "recvattach.h"
#include "mutt.h"
#include "handler.h"
#include "recvattach.h"
-#include "mutt_curses.h"
#include "mx.h"
#include "copy.h"
#include "pager.h"
#include "mx.h"
#include "copy.h"
#include "pager.h"
@@
-32,19
+48,6
@@
#include <lib-crypt/crypt.h>
#include "mutt_idna.h"
#include <lib-crypt/crypt.h>
#include "mutt_idna.h"
-#include "lib/debug.h"
-
-#include <string.h>
-#include <stdlib.h>
-#include <unistd.h>
-#include <errno.h>
-#include <ctype.h>
-#include <sys/stat.h>
-#include <signal.h>
-#include <sys/wait.h>
-#include <fcntl.h>
-#include <sys/utsname.h>
-
#ifdef USE_LIBESMTP
# include "mutt_libesmtp.h"
#endif /* USE_LIBESMTP */
#ifdef USE_LIBESMTP
# include "mutt_libesmtp.h"
#endif /* USE_LIBESMTP */
@@
-887,7
+890,7
@@
int mutt_lookup_mime_type (BODY * att, const char *path)
snprintf (buf, sizeof (buf), "%s/.mime.types", NONULL (Homedir));
break;
case 1:
snprintf (buf, sizeof (buf), "%s/.mime.types", NONULL (Homedir));
break;
case 1:
- m_strcpy(buf, sizeof(buf), SYSCONFDIR "/m
uttng
-mime.types");
+ m_strcpy(buf, sizeof(buf), SYSCONFDIR "/m
admutt
-mime.types");
break;
case 2:
m_strcpy(buf, sizeof(buf), PKGDATADIR "/mime.types");
break;
case 2:
m_strcpy(buf, sizeof(buf), PKGDATADIR "/mime.types");
@@
-1403,9
+1406,9
@@
void mutt_write_address_list (address_t * adr, FILE * fp, int linelen,
/* need to write the list in reverse because they are stored in reverse order
* when parsed to speed up threading
*/
/* need to write the list in reverse because they are stored in reverse order
* when parsed to speed up threading
*/
-void mutt_write_references (
LIST
* r, FILE * f)
+void mutt_write_references (
string_list_t
* r, FILE * f)
{
{
-
LIST
**ref = NULL;
+
string_list_t
**ref = NULL;
int refcnt = 0, refmax = 0;
for (; (TrimRef == 0 || refcnt < TrimRef) && r; r = r->next) {
int refcnt = 0, refmax = 0;
for (; (TrimRef == 0 || refcnt < TrimRef) && r; r = r->next) {
@@
-1443,7
+1446,7
@@
int mutt_write_rfc822_header (FILE * fp, ENVELOPE * env, BODY * attach,
{
char buffer[LONG_STRING];
char *p;
{
char buffer[LONG_STRING];
char *p;
-
LIST
*tmp = env->userhdrs;
+
string_list_t
*tmp = env->userhdrs;
int has_agent = 0; /* user defined user-agent header field exists */
list2_t* hdrs = list_from_str (EditorHeaders, " ");
int has_agent = 0; /* user defined user-agent header field exists */
list2_t* hdrs = list_from_str (EditorHeaders, " ");
@@
-1599,7
+1602,7
@@
int mutt_write_rfc822_header (FILE * fp, ENVELOPE * env, BODY * attach,
return (ferror (fp) == 0 ? 0 : -1);
}
return (ferror (fp) == 0 ? 0 : -1);
}
-static void encode_headers (
LIST
* h)
+static void encode_headers (
string_list_t
* h)
{
char *tmp;
char *p;
{
char *tmp;
char *p;
@@
-2024,11
+2027,8
@@
static int mutt_invoke_sendmail (address_t * from, /* the sender */
if ((i = send_msg (path, args, msg, &childout)) != (EX_OK & 0xff)) {
if (i != S_BKG) {
if ((i = send_msg (path, args, msg, &childout)) != (EX_OK & 0xff)) {
if (i != S_BKG) {
- const char *e = mutt_strsysexit (i);
-
- e = mutt_strsysexit (i);
mutt_error (_("Error sending message, child exited %d (%s)."), i,
mutt_error (_("Error sending message, child exited %d (%s)."), i,
-
NONULL (e
));
+
m_strsysexit(i
));
if (childout) {
struct stat st;
if (childout) {
struct stat st;
@@
-2171,12
+2171,12
@@
void mutt_prepare_envelope (ENVELOPE * env, int final)
void mutt_unprepare_envelope (ENVELOPE * env)
{
void mutt_unprepare_envelope (ENVELOPE * env)
{
-
LIST
*item;
+
string_list_t
*item;
for (item = env->userhdrs; item; item = item->next)
rfc2047_decode (&item->data);
for (item = env->userhdrs; item; item = item->next)
rfc2047_decode (&item->data);
- address_
delete
(&env->mail_followup_to);
+ address_
list_wipe
(&env->mail_followup_to);
/* back conversions */
rfc2047_decode_adrlist (env->to);
/* back conversions */
rfc2047_decode_adrlist (env->to);
@@
-2268,7
+2268,7
@@
int mutt_bounce_message (FILE * fp, HEADER * h, address_t * to)
ret = _mutt_bounce_message (fp, h, to, resent_from, from);
ret = _mutt_bounce_message (fp, h, to, resent_from, from);
- address_
delete
(&from);
+ address_
list_wipe
(&from);
return ret;
}
return ret;
}
@@
-2297,7
+2297,7
@@
address_t *mutt_remove_duplicates (address_t * addr)
*last = addr->next;
addr->next = NULL;
*last = addr->next;
addr->next = NULL;
- address_
delete
(&addr);
+ address_
list_wipe
(&addr);
addr = *last;
}
addr = *last;
}
@@
-2422,7
+2422,7
@@
int mutt_write_fcc (const char *path, HEADER * hdr, const char *msgid,
*/
if (post && hdr->chain && hdr->chain) {
*/
if (post && hdr->chain && hdr->chain) {
-
LIST
*p;
+
string_list_t
*p;
fputs ("X-Mutt-Mix:", msg->fp);
for (p = hdr->chain; p; p = p->next)
fputs ("X-Mutt-Mix:", msg->fp);
for (p = hdr->chain; p; p = p->next)