Static-Dynamic Body collision problem

Hello everyone,

Sorry for the haste in making the topic, but i will just copy my question from stackexchange, because im in a hurry at this time and i really need help 🙂

I have a Box2D simulation going on and a system that loads the bodies and its' shapes from a text file definition.

I create a new physics world, i load bodies into it, from one of these files. Everything seems to work fine, collisions included.

Then, i attempt to create a really simple one-shaped body from code, just like the most basic tutorials. Lets say a circle.

The circle appears fine, starts falling with gravity, and as soon as it hits a static body, both the circle and that body disapear. As simple as that. The body the circle is colliding with is in this case a ground static rectangle.. Pretty straightforward!

I think im setting everything just the regular way, but i can edit this question with more information if pertinent. Sorry for the lack of detail.

EDIT: For some reason, seems to work in Debug builds, but no in Release.

So, anyone knows any circumstances that could cause such an event?

Thanks in advance!
It disappears why? Does it fly away into space or is it not in the world at all? Is it being destroyed - what's going on in BeginContact?
They just disappear, but there is something wrong with my system, i will keep fixing things in it until it solves itself. Something is bugging Box2D in it.
So, really weird, i made a really simple function like:

Code:
void KinesisWorld::CreateQuickCircle(int x, int y, int r){
      b2BodyDef def;
      def.position = b2Vec2(ToMeters(x),ToMeters(y));
      def.type = b2_dynamicBody;

      b2CircleShape circle;
      circle.m_radius = ToMeters(r);
      circle.m_p = b2Vec2(0, 0);      

      b2Body *body = CreateBody(&def);

      b2FixtureDef fixDef;
      fixDef.shape = &circle;
      fixDef.density = 1.0f;
      fixDef.friction = 0.5f;
      fixDef.restitution = 0.5f;

      body->CreateFixture(&fixDef);
   };


Then i mapped a key to it. Just to note that the world starts with a ground shape(static) and one circle(dynamic) before any key is pressed.

Funny thing is, besides the two bodies previously created, i get to create exactly six more. Only six more. If there are 8 objects in the world, its just fine, if i press the key one time more, the bug mentioned early happens. Weird.

Sample of this bug: http://www.mediafire.com/?p9ct4sa8ycpqp39

EDIT: After testing some more, i concluded this bug is happening only when there are b2PolygonShape objects in the world. With circles it runs fine, release or debug. With boxes the bug happens, and its exactly at the count of 8 like i said, giving the following assert failure in debug mode:

Code:
Assertion failed:area > 1.192092896e-07F, ..\..\Box2D\Collision\Shapes\b2PolygonShape.cpp, line 352
i think i found the problem. What a silly thing. The size for the shapes was being generated randomly, and the randomizer is the most simplistic possible, therefore it was giving me a value of 0 at exactly the same time, which i set to my box dimensions, giving that assert a valid meaning 🙂

Original thread: https://box2d.org/forum/viewtopic.php?t=7776