comparison src/ch/ethz/ssh2/packets/PacketChannelWindowAdjust.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
24 payload = tw.getBytes(); 24 payload = tw.getBytes();
25 } 25 }
26 26
27 public PacketChannelWindowAdjust(byte payload[]) throws IOException { 27 public PacketChannelWindowAdjust(byte payload[]) throws IOException {
28 this.payload = payload; 28 this.payload = payload;
29
30 TypesReader tr = new TypesReader(payload); 29 TypesReader tr = new TypesReader(payload);
31
32 int packet_type = tr.readByte(); 30 int packet_type = tr.readByte();
33 31
34 if(packet_type != Packets.SSH_MSG_CHANNEL_WINDOW_ADJUST) { 32 if (packet_type != Packets.SSH_MSG_CHANNEL_WINDOW_ADJUST) {
35 throw new IOException( 33 throw new IOException(
36 "This is not a SSH_MSG_CHANNEL_WINDOW_ADJUST! (" 34 "This is not a SSH_MSG_CHANNEL_WINDOW_ADJUST! ("
37 + packet_type + ")" 35 + packet_type + ")"
38 ); 36 );
39 } 37 }
40 38
41 int recipientChannelID = tr.readUINT32(); 39 int recipientChannelID = tr.readUINT32();
42 int windowChange = tr.readUINT32(); 40 int windowChange = tr.readUINT32();
43 41
44 if(tr.remain() != 0) { 42 if (tr.remain() != 0) {
45 throw new PacketFormatException(String.format("Padding in %s", Packets.getMessageName(packet_type))); 43 throw new PacketFormatException(String.format("Padding in %s", Packets.getMessageName(packet_type)));
46 } 44 }
47 } 45 }
48 46
49 public byte[] getPayload() { 47 public byte[] getPayload() {