cl_hp_parse_field - Execute field parser
Contents
Description
The cl_hp_parse_field() function executes the header field parser.
This implementation executes the canlock-hfp utility in a separate process.
The parameter data should point to the beginning of the input data.
Specify the length of the input data with the data_len parameter.
The input data must be an unfolded "Cancel-Lock" or "Cancel-Key" header field without line break at the
end.
The function cl_hp_get_field() can be used to extract a field from the message header.
The function cl_hp_unfold_field() can be used to remove potential folding from an already extracted
header field.
Name
cl_hp_parse_field - Execute field parser
Reporting Bugs
Report bugs to <mailto:michael.baeuerle@gmx.net>.
Return Value
If the parser reports success, a pointer to the NUL-terminated output data is returned. Otherwise, NULL
is returned.
On success, the caller is responsible to free() the memory block allocated for the output data.
See Also
free(3), cl_hp_get_field(3), cl_hp_unfold_field(3), canlock-hfp(1), canlock-mhp(1), canlock(1) Unix 2024-05-11 cl_hp_parse_field(3)
Standards
cl_hp_parse_field() tries to comply with the following standards:
RFC 8315
Synopsis
#include<libcanlock-3/canlock-hp.h>char*cl_hp_parse_field(constchar*data,size_tdata_len);
