Creating CAD-models from scanned point clouds is widely used in prototyping, reverse engineering, and many other fields of science, culture and industry. But because of various physical and technical reasons such point cloud often contains regions with poor point density that leads to surface discontinuities in the resulting model. So, the problem of filling such discontinuities by proper surface patches is very topical. There are many solutions proposed but most of them consider only filling simple shape holes. Our group has developed a method that allows repairing even seriously damaged meshes. As distinct from existing ones, it can connect different boundaries of a specified damaged model to restore its original topology. This ability is required if the model?s surface is represented by several isolated mesh pieces or (and) if the model has one or several tunnel-like holes whose internal parts are lost due to poor scanning.