Mercurial > hg > Database > Christie-sharp
changeset 48:6e5c0977d756
bug fixed
author | riono <e165729@ie.u-ryukyu.ac.jp> |
---|---|
date | Mon, 10 Jan 2022 00:56:00 +0900 |
parents | 61ec3dd0995c |
children | 6d733b2ea461 |
files | Christie_net.csproj Test/Example/FizzBuzz/Counter.cs daemon/IncomingTcpConnection.cs datagear/WaitList.cs |
diffstat | 4 files changed, 10 insertions(+), 10 deletions(-) [+] |
line wrap: on
line diff
--- a/Christie_net.csproj Mon Jan 10 00:45:32 2022 +0900 +++ b/Christie_net.csproj Mon Jan 10 00:56:00 2022 +0900 @@ -3,7 +3,7 @@ <PropertyGroup> <OutputType>Exe</OutputType> <TargetFramework>netcoreapp3.1</TargetFramework> - <StartupObject>Christie_net.Test.Example.FizzBuzz.StartFizzBuzz</StartupObject> + <StartupObject>Christie_net.Test.Example.RemoteTake.StartRemoteTake</StartupObject> </PropertyGroup> <ItemGroup>
--- a/Test/Example/FizzBuzz/Counter.cs Mon Jan 10 00:45:32 2022 +0900 +++ b/Test/Example/FizzBuzz/Counter.cs Mon Jan 10 00:56:00 2022 +0900 @@ -11,7 +11,6 @@ if (count <= 100) { GetDgm("FizzBuzz").Put("num", count); //cgm.GetLocalDGM().Put("cunt", count+1); - Console.WriteLine("cunt:" + count); cgm.Setup(new Counter()); } else {
--- a/daemon/IncomingTcpConnection.cs Mon Jan 10 00:45:32 2022 +0900 +++ b/daemon/IncomingTcpConnection.cs Mon Jan 10 00:56:00 2022 +0900 @@ -29,15 +29,17 @@ } public void Run() { - //TODO: Data長がわからないので1024で仮置き → ぴったしで読み込む必要がある - byte[] streamData = new byte[1024]; - try { - connection.stream.Read(streamData); - } catch (Exception e) { - Console.WriteLine(e); - } + while (true) { + //TODO: Data長がわからないので1024で仮置き → ぴったしで読み込む必要がある + byte[] streamData = new byte[1024]; + try { + connection.stream.Read(streamData); + } catch (Exception e) { + Console.WriteLine(e); + } + try { // データはRemotemessage(Command), length, dataの順で入っている //int dataLength = connection.socket.Receive(deserializeCommand);