I am attempting to upgrade from ChilkatDotNet4.dll version 9.4.1.0 to 9.5.0.58 but the following code no longer works:
sshCK.SendReqExec(channelNum, "type \remote_host_Bshare_name$data.csv && echo Get_Complete"); sshCK.ChannelReceiveUntilMatch(channelNum, "Get_Complete", "ansi", false);
I am connecting to Windows host A via SSH and then having host A print the contents of a remote file on host B, and then append the keyword "Get_Complete" so I know where the data ends.
Here are my observations:
1) This works fine with 9.4.1.0 (i.e. ChannelReceiveUntilMatch() returns true) 2) If I ignore the error and call GetReceivedText(), the data that is returned is exactly what I expected to receive. 3) I tried playing around with ReadTimeoutMs, but regardless of its value the command always returns in about 25ms.
Has this command changed significantly since 9.4 and I just need to change my logic? Or is there a bug of some kind?
Thanks, Richard
Chilkat error: ChilkatLog: ChannelReceiveUntilMatch(16ms): DllDate: Jun 13 2016 ChilkatVersion: 9.5.0.58 UnlockPrefix: PETERLSSH Architecture: Little Endian; 64-bit Language: .NET 4.0 / x64 VerboseLogging: 1 channelReceiveUntilMatch(16ms): channel: 5 pattern: Get_Complete charset: ansi caseSensitive: 0 readChannelData(16ms): mType: IGNORE mType: CHANNEL_DATA dataLen: 80 clientWinSize: 327600 --readChannelData readChannelData: mType: CHANNEL_DATA dataLen: 512 clientWinSize: 327088 --readChannelData readChannelData: mType: CHANNEL_DATA dataLen: 1024 clientWinSize: 326064 --readChannelData readChannelData: mType: CHANNEL_DATA dataLen: 1968 clientWinSize: 324096 --readChannelData readChannelData: mType: CHANNEL_DATA dataLen: 512 clientWinSize: 323584 --readChannelData readChannelData: mType: IGNORE mType: CHANNEL_DATA dataLen: 80 clientWinSize: 323504 --readChannelData readChannelData: mType: CHANNEL_DATA dataLen: 944 clientWinSize: 322560 --readChannelData readChannelData: mType: CHANNEL_DATA dataLen: 512 clientWinSize: 322048 --readChannelData readChannelData: mType: CHANNEL_DATA dataLen: 400 clientWinSize: 321648 --readChannelData readChannelData: mType: CHANNEL_DATA dataLen: 512 clientWinSize: 321136 --readChannelData readChannelData: mType: CHANNEL_DATA dataLen: 784 clientWinSize: 320352 --readChannelData readChannelData: mType: CHANNEL_DATA dataLen: 80 clientWinSize: 320272 --readChannelData readChannelData: mType: CHANNEL_DATA dataLen: 784 clientWinSize: 319488 --readChannelData readChannelData: mType: IGNORE mType: CHANNEL_DATA dataLen: 80 clientWinSize: 319408 --readChannelData readChannelData: mType: CHANNEL_DATA dataLen: 1696 clientWinSize: 317712 --readChannelData readChannelData: mType: CHANNEL_DATA dataLen: 784 clientWinSize: 316928 --readChannelData readChannelData: mType: CHANNEL_DATA dataLen: 1344 clientWinSize: 315584 --readChannelData readChannelData: mType: CHANNEL_DATA dataLen: 704 clientWinSize: 314880 --readChannelData readChannelData: mType: CHANNEL_DATA dataLen: 912 clientWinSize: 313968 --readChannelData readChannelData: mType: CHANNEL_DATA dataLen: 1104 clientWinSize: 312864 --readChannelData readChannelData: mType: CHANNEL_DATA dataLen: 2746 clientWinSize: 310118 --readChannelData readChannelData: mType: CHANNEL_DATA dataLen: 14 clientWinSize: 310104 --readChannelData readChannelData: mType: IGNORE mType: CHANNEL_REQUEST Received CHANNEL REQUEST message requestType: exit-status wantReply: 0 exitStatusCode: 0 Received channel request --readChannelData readChannelData: mType: CHANNEL_EOF --readChannelData readChannelData: mType: CHANNEL_CLOSE Sent SSH Channel CLOSE --readChannelData Failed to receive until match. --channelReceiveUntilMatch Failed. --ChannelReceiveUntilMatch --ChilkatLog