follow-up 3

This commit is contained in:
nhmall
2022-06-30 13:27:46 -04:00
parent 6920632df0
commit cd57dfa5ff
4 changed files with 23 additions and 0 deletions

View File

@@ -1832,6 +1832,7 @@ extern boolean regex_compile(const char *, struct nhregex *);
extern const char *regex_error_desc(struct nhregex *);
extern boolean regex_match(const char *, struct nhregex *);
extern void regex_free(struct nhregex *);
extern void regex_at_exit(void);
/* ### consoletty.c ### */

View File

@@ -63,3 +63,13 @@ extern "C" {
delete re;
}
}
void
regex_at_exit(void)
{
if (cppregex_static_buffer != 0) {
free((genericptr_t) cppregex_static_buffer);
cppregex_static_buffer = (char *) 0;
}
}

View File

@@ -65,3 +65,9 @@ regex_free(struct nhregex *re)
free((genericptr_t) re);
}
}
void
regex_at_exit(void)
{
}

View File

@@ -104,3 +104,9 @@ regex_free(struct nhregex *re)
regfree(&re->re);
free(re);
}
void
regex_at_exit(void)
{
}