Index: cnc_text_dyn.c =================================================================== --- cnc_text_dyn.c (revision 2132) +++ cnc_text_dyn.c (revision 2133) @@ -132,14 +132,24 @@ void csch_text_dyntext_render(csch_text_t *text) { + const char *empty = ""; csch_text_dyntext_inval(text); if (text->dyntext) { gds_t tmp = {0}; rnd_subst_append(&tmp, text->text, csch_text_render_str_cb, (void *)text, RND_SUBST_PERCENT | RND_SUBST_CONF, 0); - text->rtext = tmp.array; + if ((tmp.array == NULL) || (*tmp.array == '\0')) { + text->rtext = rnd_strdup(empty); + gds_uninit(&tmp); + } + else + text->rtext = tmp.array; } - else - text->rtext = rnd_strdup(text->text); + else { + if ((text->text == NULL) || (*text->text == '\0')) + text->rtext = rnd_strdup(empty); + else + text->rtext = rnd_strdup(text->text); + } }