mirror of https://github.com/CGAL/cgal
Fix a warning [-Wcatch-value]
``` test/Polyhedron_Demo/MainWindow.cpp:1075:26: warning: catching polymorphic type 'class std::logic_error' by value [-Wcatch-value=] test/Polyhedron_Demo/Plugins/Mesh_2/Mesh_2_plugin.cpp:287:6: warning: catching polymorphic type 'class std::runtime_error' by value [-Wcatch-value=] ```
This commit is contained in:
parent
e400b3328d
commit
3f6400b40e
|
|
@ -1071,7 +1071,7 @@ bool MainWindow::open(QString filename, QString loader_name) {
|
|||
if(!item_opt) return false;
|
||||
else item = *item_opt;
|
||||
}
|
||||
catch(std::logic_error e) {
|
||||
catch(std::logic_error& e) {
|
||||
std::cerr << e.what() << std::endl;
|
||||
return false;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -284,7 +284,7 @@ private:
|
|||
Q_FOREACH(const std::vector<Kernel::Point_3>& points,
|
||||
polylines_item->polylines)
|
||||
cdt.insert_constraint(points.begin(),points.end());
|
||||
}catch(std::runtime_error)
|
||||
}catch(std::runtime_error&)
|
||||
{
|
||||
QApplication::restoreOverrideCursor();
|
||||
throw;
|
||||
|
|
|
|||
Loading…
Reference in New Issue