position error when create weld joint using box2d

I create weld joint when a body contact another to make them move together. but the position of one body goes wrong in an instant when joint created. attachment is my demo, thanks.

put the demo in projects folder of cocos2d-x2.2.1

Best,


HelloWorld.zip (1899.9 KB)