[haiku-development] Re: Fixed obvious memory leak in CLuceneDataBase

  • From: looncraz <looncraz@xxxxxxxxxxx>
  • To: haiku-development@xxxxxxxxxxxxx
  • Date: Thu, 7 Jan 2016 19:18:27 -0600

On 1/7/2016 19:07, looncraz wrote:


Shouldn't this be:

if (mbstowcs(wStr, str, size) == -1) {
delete[] wStr;
return NULL ;
} else {
return wStr ;
}


Or, more appropriately, not even the else, just return wStr;



--The loon


--The loon


Other related posts: