From f249acf5a12ec0a40584042354a4054343dc6425 Mon Sep 17 00:00:00 2001 From: deva Date: Thu, 30 Jul 2009 11:57:22 +0000 Subject: Added Exception class unit test. --- server/src/exception.cc | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'server/src/exception.cc') diff --git a/server/src/exception.cc b/server/src/exception.cc index 57bd6bf..09c6918 100644 --- a/server/src/exception.cc +++ b/server/src/exception.cc @@ -63,13 +63,19 @@ int main() throw MyException(); } catch( MyException &e ) { printf("%s\n", e.what()); + goto on; } + return 1; + on: try { throw MyExtException("Yeaaah!"); } catch( MyExtException &e ) { printf("%s\n", e.what()); + goto onandon; } + return 1; + onandon: return 0; } -- cgit v1.2.3