summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--cs/config/Make.rules2
-rwxr-xr-xcs/demo/Glacier/session/Client.cs20
-rwxr-xr-xcs/demo/Glacier/session/Server.cs20
-rwxr-xr-xcs/demo/Ice/hello/Client.cs20
-rwxr-xr-xcs/demo/Ice/hello/Server.cs20
-rwxr-xr-xcs/demo/Ice/latency/Client.cs20
-rwxr-xr-xcs/demo/Ice/latency/Server.cs20
-rwxr-xr-xcs/demo/Ice/throughput/Client.cs20
-rwxr-xr-xcs/demo/Ice/throughput/Server.cs20
-rwxr-xr-xcs/demo/Ice/value/Client.cs20
-rwxr-xr-xcs/demo/Ice/value/Server.cs22
11 files changed, 132 insertions, 72 deletions
diff --git a/cs/config/Make.rules b/cs/config/Make.rules
index 43b94b75df2..a80b631466e 100644
--- a/cs/config/Make.rules
+++ b/cs/config/Make.rules
@@ -145,7 +145,7 @@ depend:: $(SLICE_SRCS) $(SLICE_C_SRCS) $(SLICE_S_SRCS) $(SLICE_AMD_SRCS) $(SLICE
fi
clean::
- -rm -f $(TARGETS) *.bak icecs.dll
+ -rm -f $(TARGETS) *.bak icecs.dll glaciercs.dll
ifneq ($(SLICE_SRCS),)
clean::
diff --git a/cs/demo/Glacier/session/Client.cs b/cs/demo/Glacier/session/Client.cs
index 002241998da..7576c7a96e2 100755
--- a/cs/demo/Glacier/session/Client.cs
+++ b/cs/demo/Glacier/session/Client.cs
@@ -210,13 +210,19 @@ public class Client
Console.Error.WriteLine(ex);
status = 1;
}
- finally
- {
- if(communicator != null)
- {
- communicator.destroy();
- }
- }
+
+ if(communicator != null)
+ {
+ try
+ {
+ communicator.destroy();
+ }
+ catch(System.Exception ex)
+ {
+ Console.Error.WriteLine(ex);
+ status = 1;
+ }
+ }
Environment.Exit(status);
}
diff --git a/cs/demo/Glacier/session/Server.cs b/cs/demo/Glacier/session/Server.cs
index 1d7a104d727..412aa18c020 100755
--- a/cs/demo/Glacier/session/Server.cs
+++ b/cs/demo/Glacier/session/Server.cs
@@ -70,13 +70,19 @@ public class Server
Console.Error.WriteLine(ex);
status = 1;
}
- finally
- {
- if(communicator != null)
- {
- communicator.destroy();
- }
- }
+
+ if(communicator != null)
+ {
+ try
+ {
+ communicator.destroy();
+ }
+ catch(System.Exception ex)
+ {
+ Console.Error.WriteLine(ex);
+ status = 1;
+ }
+ }
Environment.Exit(status);
}
diff --git a/cs/demo/Ice/hello/Client.cs b/cs/demo/Ice/hello/Client.cs
index 8fbb7598e48..e305aaf6e9e 100755
--- a/cs/demo/Ice/hello/Client.cs
+++ b/cs/demo/Ice/hello/Client.cs
@@ -160,13 +160,19 @@ public class Client
Console.Error.WriteLine(ex);
status = 1;
}
- finally
- {
- if(communicator != null)
- {
- communicator.destroy();
- }
- }
+
+ if(communicator != null)
+ {
+ try
+ {
+ communicator.destroy();
+ }
+ catch(System.Exception ex)
+ {
+ Console.Error.WriteLine(ex);
+ status = 1;
+ }
+ }
System.Environment.Exit(status);
}
diff --git a/cs/demo/Ice/hello/Server.cs b/cs/demo/Ice/hello/Server.cs
index 5347dbffcf9..412aa18962d 100755
--- a/cs/demo/Ice/hello/Server.cs
+++ b/cs/demo/Ice/hello/Server.cs
@@ -37,13 +37,19 @@ public class Server
System.Console.Error.WriteLine(ex);
status = 1;
}
- finally
- {
- if(communicator != null)
- {
- communicator.destroy();
- }
- }
+
+ if(communicator != null)
+ {
+ try
+ {
+ communicator.destroy();
+ }
+ catch(System.Exception ex)
+ {
+ System.Console.Error.WriteLine(ex);
+ status = 1;
+ }
+ }
System.Environment.Exit(status);
}
diff --git a/cs/demo/Ice/latency/Client.cs b/cs/demo/Ice/latency/Client.cs
index 3467fe841a3..5a36c0e7432 100755
--- a/cs/demo/Ice/latency/Client.cs
+++ b/cs/demo/Ice/latency/Client.cs
@@ -69,13 +69,19 @@ public class Client
Console.Error.WriteLine(ex);
status = 1;
}
- finally
- {
- if(communicator != null)
- {
- communicator.destroy();
- }
- }
+
+ if(communicator != null)
+ {
+ try
+ {
+ communicator.destroy();
+ }
+ catch(System.Exception ex)
+ {
+ Console.Error.WriteLine(ex);
+ status = 1;
+ }
+ }
System.Environment.Exit(status);
}
diff --git a/cs/demo/Ice/latency/Server.cs b/cs/demo/Ice/latency/Server.cs
index 5ad26ffdd03..d94207874c5 100755
--- a/cs/demo/Ice/latency/Server.cs
+++ b/cs/demo/Ice/latency/Server.cs
@@ -39,13 +39,19 @@ public class Server
Console.Error.WriteLine(ex);
status = 1;
}
- finally
- {
- if(communicator != null)
- {
- communicator.destroy();
- }
- }
+
+ if(communicator != null)
+ {
+ try
+ {
+ communicator.destroy();
+ }
+ catch(System.Exception ex)
+ {
+ Console.Error.WriteLine(ex);
+ status = 1;
+ }
+ }
System.Environment.Exit(status);
}
diff --git a/cs/demo/Ice/throughput/Client.cs b/cs/demo/Ice/throughput/Client.cs
index cce67d80d49..db21e17f746 100755
--- a/cs/demo/Ice/throughput/Client.cs
+++ b/cs/demo/Ice/throughput/Client.cs
@@ -185,13 +185,19 @@ public class Client
Console.Error.WriteLine(ex);
status = 1;
}
- finally
- {
- if(communicator != null)
- {
- communicator.destroy();
- }
- }
+
+ if(communicator != null)
+ {
+ try
+ {
+ communicator.destroy();
+ }
+ catch(System.Exception ex)
+ {
+ Console.Error.WriteLine(ex);
+ status = 1;
+ }
+ }
System.Environment.Exit(status);
}
diff --git a/cs/demo/Ice/throughput/Server.cs b/cs/demo/Ice/throughput/Server.cs
index 7232181b739..47ddd0fecb4 100755
--- a/cs/demo/Ice/throughput/Server.cs
+++ b/cs/demo/Ice/throughput/Server.cs
@@ -37,13 +37,19 @@ public class Server
System.Console.Error.WriteLine(ex);
status = 1;
}
- finally
- {
- if(communicator != null)
- {
- communicator.destroy();
- }
- }
+
+ if(communicator != null)
+ {
+ try
+ {
+ communicator.destroy();
+ }
+ catch(System.Exception ex)
+ {
+ System.Console.Error.WriteLine(ex);
+ status = 1;
+ }
+ }
System.Environment.Exit(status);
}
diff --git a/cs/demo/Ice/value/Client.cs b/cs/demo/Ice/value/Client.cs
index 839f72d3113..d521f5aed0a 100755
--- a/cs/demo/Ice/value/Client.cs
+++ b/cs/demo/Ice/value/Client.cs
@@ -189,13 +189,19 @@ public class Client
Console.Error.WriteLine(ex);
status = 1;
}
- finally
- {
- if(communicator != null)
- {
- communicator.destroy();
- }
- }
+
+ if(communicator != null)
+ {
+ try
+ {
+ communicator.destroy();
+ }
+ catch(System.Exception ex)
+ {
+ Console.Error.WriteLine(ex);
+ status = 1;
+ }
+ }
System.Environment.Exit(status);
}
diff --git a/cs/demo/Ice/value/Server.cs b/cs/demo/Ice/value/Server.cs
index 005fb19dedf..f4b005b9f15 100755
--- a/cs/demo/Ice/value/Server.cs
+++ b/cs/demo/Ice/value/Server.cs
@@ -32,18 +32,24 @@ public class Server
communicator = Ice.Util.initializeWithProperties(ref args, properties);
status = run(args, communicator);
}
- catch (System.Exception ex)
+ catch(System.Exception ex)
{
System.Console.Error.WriteLine(ex);
status = 1;
}
- finally
- {
- if(communicator != null)
- {
- communicator.destroy();
- }
- }
+
+ if(communicator != null)
+ {
+ try
+ {
+ communicator.destroy();
+ }
+ catch(System.Exception ex)
+ {
+ System.Console.Error.WriteLine(ex);
+ status = 1;
+ }
+ }
System.Environment.Exit(status);
}