diff options
author | Karen Arutyunov <karen@codesynthesis.com> | 2020-04-16 18:15:45 +0300 |
---|---|---|
committer | Karen Arutyunov <karen@codesynthesis.com> | 2020-04-21 16:40:06 +0300 |
commit | fc2234b87f4ce29be0e556c6f3b085b749b7d71b (patch) | |
tree | a56f6807aa0378c9dd58286f073e57ad748891ad /libxerces-c/tests/net-accessor/handle-exception-as-error.patch | |
parent | 5d559799f0815e5bd2f510d91607a7ef1b20e3a0 (diff) |
Add implementation
Diffstat (limited to 'libxerces-c/tests/net-accessor/handle-exception-as-error.patch')
-rw-r--r-- | libxerces-c/tests/net-accessor/handle-exception-as-error.patch | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/libxerces-c/tests/net-accessor/handle-exception-as-error.patch b/libxerces-c/tests/net-accessor/handle-exception-as-error.patch new file mode 100644 index 0000000..674e5ba --- /dev/null +++ b/libxerces-c/tests/net-accessor/handle-exception-as-error.patch @@ -0,0 +1,35 @@ +diff --git a/libxerces-c/tests/net-accessor/NetAccessorTest.cpp b/libxerces-c/tests/net-accessor/NetAccessorTest.cpp +index 3bb735b..c2affbd 100644 +--- a/libxerces-c/tests/net-accessor/NetAccessorTest.cpp ++++ b/libxerces-c/tests/net-accessor/NetAccessorTest.cpp +@@ -122,6 +122,8 @@ main(int argc, char** argv) + // Get the URL + char* url = argv[1]; + ++ int r = 1; ++ + // Do the test + try + { +@@ -148,11 +150,11 @@ main(int argc, char** argv) + + // Delete the is + delete is; +- ++ r = 0; + } + catch(const XMLException& toCatch) + { +- XERCES_STD_QUALIFIER cout << "Exception during test:\n " ++ XERCES_STD_QUALIFIER cerr << "Exception during test:\n " + << toCatch.getMessage() + << XERCES_STD_QUALIFIER endl; + } +@@ -160,6 +162,6 @@ main(int argc, char** argv) + // And call the termination method + XMLPlatformUtils::Terminate(); + +- return 0; ++ return r; + } + |