X-Git-Url: http://git.marmaro.de/?p=mmh;a=blobdiff_plain;f=uip%2Fsendsbr.c;h=f793b1c83feea36ffbff4b150cadca702eba4989;hp=75768893f16d857d43fb0bbdcad62e77534556d9;hb=1bb1f6c3f38b05060bf699ea2743f7386889bf63;hpb=7480dbc14bc90f2d872d434205c0784704213252 diff --git a/uip/sendsbr.c b/uip/sendsbr.c index 7576889..f793b1c 100644 --- a/uip/sendsbr.c +++ b/uip/sendsbr.c @@ -15,6 +15,7 @@ #include #include #include +#include #ifdef TIME_WITH_SYS_TIME # include @@ -208,8 +209,7 @@ attach(char *attachment_header_field_name, char *draft_file_name) * This buffer might need to be quite large, so we grow it as needed. */ - if ((field = (char *)malloc(field_size = 256)) == (char *)0) - adios(NULL, "can't allocate field buffer."); + field = (char *)mh_xmalloc(field_size = 256); /* * Scan the draft file for a header field name that matches the -attach @@ -360,8 +360,7 @@ get_line(void) } if (++n >= field_size - 1) { - if ((field = (char *)realloc((void *)field, field_size += 256)) == (char *)0) - adios(NULL, "can't grow field buffer."); + field = (char *)mh_xrealloc((void *)field, field_size += 256); p = field + n - 1; } @@ -1020,7 +1019,7 @@ annoaux (int fd) if (is_selected(mp, msgnum)) { if (debugsw) advise (NULL, "annotate message %d", msgnum); - annotate (m_name (msgnum), annotext, cp, inplace, 1, 0, 0); + annotate (m_name (msgnum), annotext, cp, inplace, 1, -2, 0); } }