aboutsummaryrefslogtreecommitdiff
path: root/tests/regex/driver.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'tests/regex/driver.cxx')
-rw-r--r--tests/regex/driver.cxx5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/regex/driver.cxx b/tests/regex/driver.cxx
index 3f6129a..5e96f06 100644
--- a/tests/regex/driver.cxx
+++ b/tests/regex/driver.cxx
@@ -74,6 +74,11 @@ try
return r.second ? 0 : 1;
}
+catch (const regex_error& e)
+{
+ cerr << "invalid regex" << e << endl; // Print sanitized.
+ return 2;
+}
catch (const exception& e)
{
cerr << e << endl;