re_comp(3) - Linux man page
Name
re_comp, re_exec - BSD regex functionsSynopsis
#define _REGEX_RE_COMP#include <sys/types.h>
#include <regex.h>
char *re_comp(char *regex);
int re_exec(char *string);
Description
re_exec() is used to assess whether the null-terminated string pointed to by string matches the previously compiled regex.
Return Value
re_comp() returns NULL on successful compilation of regex otherwise it returns a pointer to an appropriate error message.re_exec() returns 1 for a successful match, zero for failure.