[SimGrid-user] Rép : Re: Dynar issues

Arnaud Giersch arnaud.giersch at iut-bm.univ-fcomte.fr
Thu Feb 14 17:20:37 CET 2013


Jeudi 14 février 2013, vers 15:14:25 (+0100), Christophe ENDERLIN a
écrit :

> Well, I made some tests with this tip and it doesn't seem to work.
> If I use the break keyword to interrupt an xbt_dynar_foreach loop, then I'm not able
> to traverse the dynar once more, it enters into an endless loop.
> If I don't use this keyword, then I'm able to run as many xbt_dynar_foreach loops as
> I want.
> It looks like a bug, I think ...

You're right.  It's likely a bug in your code.  With synchronized
dynars, you have to call xbt_dynar_cursor_unlock() before the break.

See the documentation at:
http://simgrid.gforge.inria.fr/simgrid/3.8.1/ref_guide/html/group__XBT__dynar__cursor.html

Note that synchronized dynars don't exist anymore since SimGrid 3.9.

Arnaud
-- 
http://info.iut-bm.univ-fcomte.fr/staff/giersch/



More information about the Simgrid-user mailing list