From: Jon Trulson Date: Thu, 12 Apr 2018 17:30:59 +0000 (-0600) Subject: dtfile/SharedProcs: CID 175229 X-Git-Tag: 2.2.4a~86 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=1321d4c299781fc72fcbdd9eb842758a49b31a92;p=oweals%2Fcde.git dtfile/SharedProcs: CID 175229 --- diff --git a/cde/programs/dtfile/SharedProcs.c b/cde/programs/dtfile/SharedProcs.c index 0a762695..c46a219e 100644 --- a/cde/programs/dtfile/SharedProcs.c +++ b/cde/programs/dtfile/SharedProcs.c @@ -1348,7 +1348,7 @@ BuildBufferFileName (char *file_name, /* * This is a function for building a buffer name using predfined input * and name template information from the types database. - * WARNING: template_input will be freed. It must point to a char *. + * WARNING: template_input MAY be freed. It must point to a char *. */ static char * @@ -1374,12 +1374,11 @@ RetrieveAndUseNameTemplateInfo( sprintf(buffer_name, name_template, template_input); DtDtsFreeAttributeValue(name_template); XtFree(template_input); - XtFree(name_template); return(buffer_name); } else { - XtFree(name_template); + DtDtsFreeAttributeValue(name_template); return(template_input); } }