TSMimeHdrFieldCreate

    include <ts/ts.h>

    TSMimeHdrFieldCreateNamed(TSMBuffer bufp, hdr, const char * name, int name_len, TSMLoc * out)

    Description

    TSMimeHdrFieldCreate() creates a completely empty field which must be named before being used in a header, usually via . It is almost always more convenient to use which combines these two steps, creating the field and then setting the name to name.

    The field created is not in a header even though it is in the same buffer. It can be added to a header with . The field also has no value, only a name. If a value is needed it must be added explicitly with a function such as TSMimeHdrFieldValueIntSet().