Change charset_iter() behaviour..
commitedc3226e901ff043629c2ac5927bf2bf37b8bac3
authorSteffen (Daode) Nurpmeso <sdaoden@users.sf.net>
Sat, 5 Apr 2014 19:47:43 +0000 (5 21:47 +0200)
committerSteffen (Daode) Nurpmeso <sdaoden@users.sf.net>
Sat, 5 Apr 2014 20:38:36 +0000 (5 22:38 +0200)
tree972b152bbb13ce6d15985450a7534ec1d8c43c83
parentafffd304aa06af99065c466cbfecb797cf47f5bc
Change charset_iter() behaviour..

charset_iter_reset()
  already go to the first valid slot (if any) instead of only
  initializing.
  Do not append charset_get_8bit() unless we HAVE_ICONV,
  otherwise the only member is now charset_get_lc() a.k.a.
  *ttycharset*!

charset_iter_next()
  only step ahead, return nothing

charset_iter()
  renamed from charset_iter_current()

charset_iter_is_valid()
  added -- wether _iter() will return NULL

charset_get_8bit():
  conditionalize availability on HAVE_ICONV.

In mime.c, generalize the used scheme and make it more explicitly
by using _CS_ITER_GET() instead of _CHARSET().
XXX All of this was preliminary (in January 2013) because the
XXX iterator will be part of the send carrier structure after the
XXX MIME/send rewrite, but add comments which state so.  It turns
XXX out to take a much longer time until we get there, so prevent
XXX even more memory-loss caused bugs as time goes by...

Adjust all use cases of the iterator to follow that, and, while
here, allow some MIME functions to fail with error; this was not
yet possible, though of course the iterator may run out of
conversions.
attachments.c
extern.h
mime.c
sendout.c