Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Apply formatting fixes from soundness check
  • Loading branch information
gwynne committed Nov 22, 2021
commit eb24beb09086c3972fe92354c65885170f1b361d
6 changes: 3 additions & 3 deletions Sources/NIOSSH/Child Channels/ChildChannelOptions.swift
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public struct SSHChildChannelOptions {

/// - seealso: `SSHChannelTypeOption`.
public static let sshChannelType: SSHChildChannelOptions.Types.SSHChannelTypeOption = .init()

/// - seealso: `PeerMaximumMessageLengthOption`.
public static let peerMaximumMessageLength: SSHChildChannelOptions.Types.PeerMaximumMessageLengthOption = .init()
}
Expand Down Expand Up @@ -56,11 +56,11 @@ extension SSHChildChannelOptions.Types {

public init() {}
}

/// `PeerMaximumMessageLengthOption` allows users to query the maximum packet size value reported by the remote peer for a given channel.
public struct PeerMaximumMessageLengthOption: ChannelOption {
public typealias Value = UInt32

public init() {}
}
}
2 changes: 1 addition & 1 deletion Tests/NIOSSHTests/ChildChannelMultiplexerTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -1751,7 +1751,7 @@ final class ChildChannelMultiplexerTests: XCTestCase {
let channelID = self.assertChannelOpen(harness.flushedMessages.first)
XCTAssertNoThrow(try harness.multiplexer.receiveMessage(self.openConfirmation(originalChannelID: channelID!, peerChannelID: 1, initialWindowSize: 5, maxPacketSize: 4247)))
XCTAssertTrue(channel.isWritable)

XCTAssertEqual(try channel.getOption(SSHChildChannelOptions.peerMaximumMessageLength).wait(), 4247)
}
}
Expand Down