Skip to content
Snippets Groups Projects
Commit dcade4ee authored by Christoph Grüninger's avatar Christoph Grüninger
Browse files

Merge branch 'feature/adjust-exception-handling' into 'master'

Don't throw std::exception but print message and exit

Fixes core/dune-common#23

See merge request !39
parents 92f5c68f fb2ba881
No related branches found
No related tags found
1 merge request!39Don't throw std::exception but print message and exit
......@@ -52,7 +52,8 @@ int main (int argc, char** argv)
}
catch (std::exception& e)
{
throw;
std::cout << "ERROR: " << e.what() << std::endl;
return 1;
}
catch (...)
{
......
......@@ -190,7 +190,8 @@ try
}
catch (std::exception &e)
{
throw;
std::cout << "ERROR: " << e.what() << std::endl;
return 1;
}
catch (...)
{
......
......@@ -133,7 +133,8 @@ try
}
catch (std::exception &e)
{
throw;
std::cout << "ERROR: " << e.what() << std::endl;
return 1;
}
catch (...)
{
......
......@@ -550,7 +550,8 @@ int main (int argc , char ** argv)
}
catch(std::exception& e)
{
throw;
std::cout << "ERROR: " << e.what() << std::endl;
return 1;
}
catch (...)
{
......
......@@ -152,7 +152,8 @@ try
}
catch (std::exception &e)
{
throw;
std::cout << "ERROR: " << e.what() << std::endl;
return 1;
}
catch (...)
{
......
......@@ -259,7 +259,8 @@ try
}
catch (std::exception &e)
{
throw;
std::cout << "ERROR: " << e.what() << std::endl;
return 1;
}
catch (...)
{
......
......@@ -92,7 +92,8 @@ try
}
catch (std::exception &e)
{
throw;
std::cout << "ERROR: " << e.what() << std::endl;
return 1;
}
catch (...)
{
......
......@@ -190,7 +190,8 @@ int main(int argc, char** argv)
}
catch (std::exception &e)
{
throw;
std::cout << "ERROR: " << e.what() << std::endl;
return 1;
}
catch (...) {
std::cerr << "Unknown exception thrown!" << std::endl;
......
......@@ -75,7 +75,8 @@ int main(int argc, char** argv)
}
catch (std::exception &e)
{
throw;
std::cout << "ERROR: " << e.what() << std::endl;
return 1;
}
catch (...)
{
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment