NeoMutt  2024-10-02-37-gfa9146
Teaching an old dog new tricks
DOXYGEN
Loading...
Searching...
No Matches
message.c
Go to the documentation of this file.
1
29#include "config.h"
30#include "mutt/lib.h"
31#include "message.h"
32
37void message_free(struct Message **ptr)
38{
39 if (!ptr || !*ptr)
40 return;
41
42 struct Message *msg = *ptr;
43 FREE(&msg->path);
44 FREE(&msg->committed_path);
45
46 FREE(ptr);
47}
48
53struct Message *message_new(void)
54{
55 return mutt_mem_calloc(1, sizeof(struct Message));
56}
struct Message * message_new(void)
Create a new Message.
Definition: message.c:53
void message_free(struct Message **ptr)
Free a Message.
Definition: message.c:37
void * mutt_mem_calloc(size_t nmemb, size_t size)
Allocate zeroed memory on the heap.
Definition: memory.c:51
#define FREE(x)
Definition: memory.h:45
Convenience wrapper for the library headers.
Message logging.
A local copy of an email.
Definition: message.h:34
char * path
path to temp file
Definition: message.h:36
char * committed_path
the final path generated by mx_msg_commit()
Definition: message.h:37