summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorfcolin2007-02-01 10:02:00 +0000
committerfcolin2007-02-01 10:02:00 +0000
commit49ba387f63b5f4251954cc553e980709c9823bc5 (patch)
treecafab7ad5b3a5e537986f1189556f22cf4b818da
parent4d81e74fd229126493df0b9bb1f01549456a9b24 (diff)
downloadivy-csharp-49ba387f63b5f4251954cc553e980709c9823bc5.zip
ivy-csharp-49ba387f63b5f4251954cc553e980709c9823bc5.tar.gz
ivy-csharp-49ba387f63b5f4251954cc553e980709c9823bc5.tar.bz2
ivy-csharp-49ba387f63b5f4251954cc553e980709c9823bc5.tar.xz
Utilisateur : Fcolin Date : 10/02/06 Heure : 15:31 Archivé dans $/CSharp/Ivy/Ivy Commentaire: endof stream throw exception (vss 10)
-rw-r--r--CSharp/Ivy/IvyPPC/IvyTCPStreamV3.cs6
1 files changed, 4 insertions, 2 deletions
diff --git a/CSharp/Ivy/IvyPPC/IvyTCPStreamV3.cs b/CSharp/Ivy/IvyPPC/IvyTCPStreamV3.cs
index 9d6d828..ab1de39 100644
--- a/CSharp/Ivy/IvyPPC/IvyTCPStreamV3.cs
+++ b/CSharp/Ivy/IvyPPC/IvyTCPStreamV3.cs
@@ -135,7 +135,8 @@ namespace IvyBus
do
{
read = input.Read();
- if (read < 0) break;
+ if (read < 0)
+ throw new EndOfStreamException();
digit = (char)read;
if (Char.IsDigit(digit))
ret = (ushort)(ret * 10 + (digit - 0x30));
@@ -151,7 +152,8 @@ namespace IvyBus
do
{
read = input.Read();
- if (read < 0) break;
+ if (read < 0)
+ throw new EndOfStreamException();
car = (char)read;
if (car != sep ) str.Append(car);
} while (car != sep);