Attachment Content-ID header functions. More...
Go to the source code of this file.
Data Structures | |
struct | CidMap |
List of Content-ID to filename mappings. More... | |
Functions | |
STAILQ_HEAD (CidMapList, CidMap) | |
void | cid_map_free (struct CidMap **ptr) |
Free a CidMap. | |
struct CidMap * | cid_map_new (const char *cid, const char *filename) |
Initialise a new CidMap. | |
void | cid_map_list_clear (struct CidMapList *cid_map_list) |
Empty a CidMapList. | |
void | cid_save_attachments (struct Body *body, struct CidMapList *cid_map_list) |
Save all attachments in a "multipart/related" group with a Content-ID. | |
void | cid_to_filename (struct Buffer *filename, const struct CidMapList *cid_map_list) |
Replace Content-IDs with filenames. | |
Attachment Content-ID header functions.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.
Definition in file cid.h.
STAILQ_HEAD | ( | CidMapList | , |
CidMap | |||
) |
void cid_map_free | ( | struct CidMap ** | ptr | ) |
struct CidMap * cid_map_new | ( | const char * | cid, |
const char * | filename | ||
) |
Initialise a new CidMap.
cid | Content-ID to replace including "cid:" prefix |
filename | Path to file to replace Content-ID with |
ptr | Newly allocated CidMap |
Definition at line 65 of file cid.c.
void cid_map_list_clear | ( | struct CidMapList * | cid_map_list | ) |
Empty a CidMapList.
cid_map_list | List of Content-ID to filename mappings |
Definition at line 82 of file cid.c.
void cid_save_attachments | ( | struct Body * | body, |
struct CidMapList * | cid_map_list | ||
) |
Save all attachments in a "multipart/related" group with a Content-ID.
[in] | body | First body in "multipart/related" group |
[out] | cid_map_list | List of Content-ID to filename mappings |
Definition at line 151 of file cid.c.
void cid_to_filename | ( | struct Buffer * | filename, |
const struct CidMapList * | cid_map_list | ||
) |
Replace Content-IDs with filenames.
filename | Path to file to replace Content-IDs with filenames |
cid_map_list | List of Content-ID to filename mappings |
Definition at line 170 of file cid.c.