[Subject Prev][Subject Next][Thread Prev][Thread Next][Date Index][Thread Index]

[hts-users:01512] Possible memory leakage in HMGenS


Hi Heiga,

At the end of the function DoGenenration() in HMGenS.c:

   /* free memory */
   Dispose(&gstack, ++utt->o);
   ResetGenInfo(genInfo);

I think since utt->o is made by MakeObservation(), it should be first
freed like this:

   for (t=utt->T; t>0; t--) {
      ResetObservation(&gstack, &utt->o[t], hset->swidth, 0);
   }

valgrind doesn't report memory loss whether adding or removing the
above lines. And I'm not sure about this. Could you please check?


With kind regards,

Xuchen

Follow-Ups
[hts-users:01513] Re: Possible memory leakage in HMGenS, Heiga ZEN (Byung Ha CHUN)