summaryrefslogtreecommitdiff
path: root/CSharp/Ivy
diff options
context:
space:
mode:
authorfcolin2007-02-01 09:51:27 +0000
committerfcolin2007-02-01 09:51:27 +0000
commit2d7d2403bf1d4e472881accf447d6497d5971703 (patch)
treed20c656949d032048e4134e94b6507a3cec5a45e /CSharp/Ivy
parent9604be1c10fef32d32fcc5cbd10a8f2ebc2b3979 (diff)
downloadivy-csharp-2d7d2403bf1d4e472881accf447d6497d5971703.zip
ivy-csharp-2d7d2403bf1d4e472881accf447d6497d5971703.tar.gz
ivy-csharp-2d7d2403bf1d4e472881accf447d6497d5971703.tar.bz2
ivy-csharp-2d7d2403bf1d4e472881accf447d6497d5971703.tar.xz
Utilisateur : Fcolin Date : 11/11/03 Heure : 20:54 Archivé dans $/EScribe/Ivy Commentaire: (vss 6)
Diffstat (limited to 'CSharp/Ivy')
-rw-r--r--CSharp/Ivy/Ivy/IvyWatcher.cs14
1 files changed, 4 insertions, 10 deletions
diff --git a/CSharp/Ivy/Ivy/IvyWatcher.cs b/CSharp/Ivy/Ivy/IvyWatcher.cs
index d14b67b..dc8343f 100644
--- a/CSharp/Ivy/Ivy/IvyWatcher.cs
+++ b/CSharp/Ivy/Ivy/IvyWatcher.cs
@@ -48,6 +48,7 @@ namespace IvyBus
this.domainaddr = domainaddr;
this.port = port;
listenThread = new Thread(new ThreadStart(this.Run));
+ listenThread.Name = "Ivy UDP Listener Thread";
// create the MulticastSocket
try
{
@@ -125,12 +126,6 @@ namespace IvyBus
Console.Error.WriteLine("can't connect to " + remotehost + " port " + port + " \n"+ e.Message);
}
}
- catch (ThreadInterruptedException te)
- {
- Console.Error.WriteLine( te.Message );
- Console.Error.WriteLine( te.StackTrace);
- running = false;
- }
catch (IOException jii)
{
running = false;
@@ -155,12 +150,11 @@ namespace IvyBus
lock(this)
{
traceDebug("begining stopping an IvyWatcher");
- Thread t = listenThread;
- listenThread = null;
broadcast.Close();
- if (t != null)
+ if (listenThread != null)
{
- t.Interrupt();
+ listenThread.Join();
+ listenThread = null;
}
// it might not even have been created
traceDebug("ending stopping an IvyWatcher");