Mercurial > 510Connectbot
comparison src/ch/ethz/ssh2/packets/PacketChannelOpenConfirmation.java @ 307:071eccdff8ea ganymed
fix java formatting
author | Carl Byington <carl@five-ten-sg.com> |
---|---|
date | Wed, 30 Jul 2014 14:16:58 -0700 |
parents | 91a31873c42a |
children |
comparison
equal
deleted
inserted
replaced
305:d2b303406d63 | 307:071eccdff8ea |
---|---|
37 payload = tw.getBytes(); | 37 payload = tw.getBytes(); |
38 } | 38 } |
39 | 39 |
40 public PacketChannelOpenConfirmation(byte payload[]) throws IOException { | 40 public PacketChannelOpenConfirmation(byte payload[]) throws IOException { |
41 this.payload = payload; | 41 this.payload = payload; |
42 | |
43 TypesReader tr = new TypesReader(payload); | 42 TypesReader tr = new TypesReader(payload); |
44 | |
45 int packet_type = tr.readByte(); | 43 int packet_type = tr.readByte(); |
46 | 44 |
47 if(packet_type != Packets.SSH_MSG_CHANNEL_OPEN_CONFIRMATION) { | 45 if (packet_type != Packets.SSH_MSG_CHANNEL_OPEN_CONFIRMATION) { |
48 throw new PacketTypeException(packet_type); | 46 throw new PacketTypeException(packet_type); |
49 } | 47 } |
50 | 48 |
51 recipientChannelID = tr.readUINT32(); | 49 recipientChannelID = tr.readUINT32(); |
52 senderChannelID = tr.readUINT32(); | 50 senderChannelID = tr.readUINT32(); |
53 initialWindowSize = tr.readUINT32(); | 51 initialWindowSize = tr.readUINT32(); |
54 maxPacketSize = tr.readUINT32(); | 52 maxPacketSize = tr.readUINT32(); |
55 | 53 |
56 if(tr.remain() != 0) { | 54 if (tr.remain() != 0) { |
57 throw new PacketFormatException(String.format("Padding in %s", Packets.getMessageName(packet_type))); | 55 throw new PacketFormatException(String.format("Padding in %s", Packets.getMessageName(packet_type))); |
58 } | 56 } |
59 } | 57 } |
60 | 58 |
61 public int getRecipientChannelID() { | 59 public int getRecipientChannelID() { |