From: Alexander S.K. <al...@be...> - 2004-10-20 06:40:59
|
On 19.10.2004 16:57, Lorenzo Fiorini <lor...@te...> wrote: >> Yes, now I get it, too. Was the same before, or it is introduced with a >> last changes ? LF> I think it was the same before. I'm not sure about a.prg but here is a msg I sent to you LF> the July 29 2004 about grid_5.prg: Now I've found the roots. The fm.log for grid_5.prg is caused by a real bug in the grid.c: HB_FUNC( LISTVIEW_SETDISPINFO ) { PHB_ITEM pValue = hb_itemNew( NULL ); LV_DISPINFO* pDispInfo = (LV_DISPINFO*)hb_parnl(1); hb_itemCopy( pValue, hb_param( 2, HB_IT_STRING )); pDispInfo->item.pszText = pValue->item.asString.value; if (pDispInfo->item.iSubItem == 0) pDispInfo->item.state = 2; } The pValue item isn't released there and the string, assigned to the pDispInfo->item.pszText, is never released, too. This function and all related code should be fully rewritten. It would be nice if Rodrigo could look at it. The problem with a.prg is very interesting. It doesn't appear in modal dialogs, only in nonmodal and in MDI Child windows and is caused by the fact that variables, used in GET items, are declared as local in the window creation procedure and are released before the window is closed ! To check this, just move these variables declaration to the main procedure and make them Private - you'll see the difference. There is a difference in handling of local variables and codeblocks in Harbour and xHarbour ( I don't know, which one is more correct ), so this doesn't cause problems in Harbour. Regards, Alexander http://kresin.belgorod.su |