X-Git-Url: https://diplodocus.org/git/nmh/blobdiff_plain/a97c3e637eaf2e2f4ecd8cb93b11795afb980988..ffe0615cdabdb2fd43c9cae6aaaf99a8831c2c10:/sbr/fmt_compile.c diff --git a/sbr/fmt_compile.c b/sbr/fmt_compile.c index 01473342..9ef39467 100644 --- a/sbr/fmt_compile.c +++ b/sbr/fmt_compile.c @@ -212,7 +212,6 @@ static struct ftable functable[] = { { "friendly", TF_COMP, FT_LS_FRIENDLY, FT_PARSEADDR, TFL_PUTS }, { "mymbox", TF_COMP, FT_LV_COMPFLAG, FT_MYMBOX, TFL_PUTN }, - { "addtoseq", TF_STR, FT_ADDTOSEQ, 0, 0 }, { "unquote", TF_EXPR, FT_LS_UNQUOTE, 0, TFL_PUTS}, @@ -857,6 +856,24 @@ fmt_free(struct format *fmt, int reset_comptable) free_comptable(); } +/* + * Free just the text strings from all of the component hash table entries + */ + +void +fmt_freecomptext(void) +{ + unsigned int i; + struct comp *cm; + + for (i = 0; i < sizeof(wantcomp)/sizeof(wantcomp[0]); i++) + for (cm = wantcomp[i]; cm; cm = cm->c_next) + if (cm->c_text) { + free(cm->c_text); + cm->c_text = NULL; + } +} + /* * Find a component in our hash table. This is just a public interface to * the FINDCOMP macro, so we don't have to expose our hash table.