diff --git a/cde/lib/DtHelp/FormatCCDF.c b/cde/lib/DtHelp/FormatCCDF.c index 1fb4eb8c3..c053d736e 100644 --- a/cde/lib/DtHelp/FormatCCDF.c +++ b/cde/lib/DtHelp/FormatCCDF.c @@ -684,7 +684,11 @@ AllocateSegments ( priv = (FrmtPrivateInfo *) realloc ((void *) priv, sizeof(FrmtPrivateInfo) * new_size); if (NULL == priv) + { + free(p_seg); + p_seg = NULL; return NULL; + } /* * reattach the private information with their segments.