NeoMutt  2022-04-29-249-gaae397
Teaching an old dog new tricks
DOXYGEN
List Data Free API

Prototype for a function to free List data. More...

Functions

static void attachmatch_free (struct AttachMatch **ptr)
 Free an AttachMatch - Implements list_free_t -. More...
 

Detailed Description

Prototype for a function to free List data.

Parameters
[out]ptrData to free

Function Documentation

◆ attachmatch_free()

static void attachmatch_free ( struct AttachMatch **  ptr)
static

Free an AttachMatch - Implements list_free_t -.

Parameters
ptrAttachMatch to free
Note
We don't free minor because it is either a pointer into major, or a static string.

Definition at line 68 of file attachments.c.

69{
70 if (!ptr || !*ptr)
71 return;
72
73 struct AttachMatch *am = *ptr;
74 regfree(&am->minor_regex);
75 FREE(&am->major);
76 FREE(ptr);
77}
#define FREE(x)
Definition: memory.h:43
An attachment matching a regex for attachment counter.
Definition: attachments.c:48
regex_t minor_regex
Minor mime type regex.
Definition: attachments.c:52
const char * major
Major mime type, e.g. "text".
Definition: attachments.c:49
+ Here is the caller graph for this function: