Nothing "happens" to these children. They are born with dual nationality, and China recognizes them as Chinese citizens, and the other country recognizes them as that country's citizens.
Note that this can happen in at least 3 ways:
- A child born in China to at least one Chinese citizen parent, and a foreign parent who can automatically passes the foreign citizenship onto the child at birth. The child is automatically a Chinese citizen under Article 4 of the Nationality Law.
- A child born outside China in a jus soli country to two Chinese citizen parents, neither of whom have permanent residence abroad. The child is automatically a Chinese citizen under Article 5 of the Nationality Law.
- A child born outside China to one Chinese citizen parent who does not have permanent residence abroad and a foreign parent, and either the foreign parent can automatically passes the foreign citizenship onto the child at birth, or the child is born in a jus soli country. The child is automatically a Chinese citizen under Article 5 of the Nationality Law.
(Note that in the last two cases the Chinese citizen parent(s) must not have permanent residence abroad, because under the second part of Article 5, the child born abroad will not be a Chinese citizen if at least one parent is a Chinese citizen who has "settled abroad", and the child has a foreign nationality at birth.)
Chinese consulates abroad will issue "Chinese Travel Documents" (which are valid for 2 years) to these dual-citizen children for travel into and out of China, instead of Chinese passports. These Chinese Travel Documents are passport-like booklets which say inside them "The bearer of this travel document is a citizen of the People's Republic of China." One can leave China with this Travel Document in combination with a foreign passport without problems, whereas there will likely be problems if one tried to leave China with a Chinese passport and a foreign passport. If the child is born in China or the child's Chinese Travel Document expired or is lost in China, and they wish to leave China they can apply for an Entry/Exit Permit to leave China (in combination with their foreign passport), and then obtain a Chinese Travel Document at a Chinese consulate abroad before the next time they wish to enter China.
These dual-citizen children can be added to hukou in Mainland China, and can otherwise stay in China without limit even if they are not added to hukou.
Some people claim that dual-citizen children somehow have to "choose" their nationality when they turn 18. However, there isn't actually any provision in the Chinese Nationality Law that provides for this, and the law does not provide for Chinese nationality to be automatically lost at any age for not renouncing foreign nationality. One possibility is that Chinese consulates might refuse to issue Chinese Travel Documents to these dual-national children after they turn 18; I don't know whether this happens or not.