From b10f09ff4c6265700560fbcdf322bc17e683c155 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 10:03:12 +0000 Subject: Utilisateur : Fcolin Date : 30/07/03 Heure : 10:01 Archivé dans $/EScribe/Ivy Commentaire: diff bug on mono on Int32.Parse (vss 4) --- CSharp/Ivy/IvyPPC/IvyWatcher.cs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/CSharp/Ivy/IvyPPC/IvyWatcher.cs b/CSharp/Ivy/IvyPPC/IvyWatcher.cs index 305e749..1815a04 100644 --- a/CSharp/Ivy/IvyPPC/IvyWatcher.cs +++ b/CSharp/Ivy/IvyPPC/IvyWatcher.cs @@ -97,12 +97,13 @@ namespace IvyBus IPAddress remotehost = remoteEP.Address; traceDebug("BUSWATCHER Receive Broadcast from " + Dns.GetHostName() + ":" + remoteEP.Port); // TODO if ( !isInDomain( remotehost ) ) continue; - String[] st = msg.Split(' '); - if (st.Length != 2) + String[] st = msg.Split(new char[]{' ','\n'},3); + if (st.Length != 3) { Console.Error.WriteLine("Bad format " + msg); continue; } + int version = Int32.Parse(st[0]); port = Int32.Parse(st[1]); if (version != Ivy.PROCOCOLVERSION) -- cgit v1.1