mail: new options to read attachments from file descriptors
* mail/mail.c (default_encoding,default_content_type) (content_name,content_filename): New statics. (cli_attach): Use the value of --content-name option as the content-type name parameter. The "-" argument instructs the program to read attachment from stdin (eqv --attach-fd=0) (cli_attach_fd): New function. (mail_options): New options: --content-name, --content-filename, --attach-fd * mail/mail.h (send_attach_file_default): Remove. (send_attach_file): New proto. * mail/send.c (atchinfo): New fields: id, name, source. (atchinfo_free): Update. (default_encoding,default_content_type): Remove globals. (send_attach_file): Rewrite. (send_attach_file_default): Remove. (escape_list_attachments): Print attachment identifier instead of the file name, which can be NULL. (saveatt): Use mu_attachment_create and mu_attachment_copy_from_stream. * NEWS: Update. * doc/texinfo/programs.texi: Document the new options.
Showing
5 changed files
with
312 additions
and
28 deletions
-
Please register or sign in to post a comment