summaryrefslogtreecommitdiff
path: root/examples/Event_Comm/supplier.cpp
diff options
context:
space:
mode:
authorparsons <parsons@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2011-10-03 21:02:32 +0000
committerparsons <parsons@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2011-10-03 21:02:32 +0000
commit4dcca24c609008f9fe8a4e01966702b8f4c08e61 (patch)
tree6bf00b87749636ef3ea7ec22a9b13d4dd2597378 /examples/Event_Comm/supplier.cpp
parent8c7cc4d18ddf28a18a01fef53aaea68422b2fff2 (diff)
downloadATCD-alt_mapping_SAIC.tar.gz
Merged version 94552 from main trunk into this branchalt_mapping_SAIC
Diffstat (limited to 'examples/Event_Comm/supplier.cpp')
-rw-r--r--examples/Event_Comm/supplier.cpp23
1 files changed, 16 insertions, 7 deletions
diff --git a/examples/Event_Comm/supplier.cpp b/examples/Event_Comm/supplier.cpp
index 7991b1e4631..97431ab7973 100644
--- a/examples/Event_Comm/supplier.cpp
+++ b/examples/Event_Comm/supplier.cpp
@@ -70,14 +70,23 @@ ACE_TMAIN(int argc, ACE_TCHAR *argv[])
// Initialize server daemon.
Supplier supplier;
- if (supplier.init (argc, argv) == -1)
- ACE_ERROR_RETURN ((LM_ERROR,
- "%p\n",
- "supplier init failed"),
- 1);
+ try
+ {
+
+ if (supplier.init (argc, argv) == -1)
+ ACE_ERROR_RETURN ((LM_ERROR,
+ "%p\n",
+ "supplier init failed"),
+ 1);
- // Loop forever handling events.
- supplier.run ();
+ // Loop forever handling events.
+ supplier.run ();
+ }
+ catch (const ::CORBA::Exception &e)
+ {
+ e._tao_print_exception ("Caught unexpected CORBA exception : ");
+ return 1;
+ }
return 0;
}