Skip to content

Commit

Permalink
修改握手信息
Browse files Browse the repository at this point in the history
  • Loading branch information
jinyuttt committed Dec 12, 2018
1 parent 0c78d44 commit d7ed4f7
Showing 1 changed file with 5 additions and 10 deletions.
15 changes: 5 additions & 10 deletions judt/src/udt/packets/ConnectionHandshake.java
Original file line number Diff line number Diff line change
Expand Up @@ -89,20 +89,15 @@ void decode(byte[]data){
if(data.length>28){
cookie=PacketUtil.decode(data, 28);
}
if(data.length>32)
{
//cd
cookie=PacketUtil.decode(data, 32);
}
if(data.length>36)
if(data.length>32)
{
peerIP[0]=PacketUtil.decode(data, 36);
peerIP[0]=PacketUtil.decode(data, 32);

peerIP[1]=PacketUtil.decode(data, 40);
peerIP[1]=PacketUtil.decode(data, 34);

peerIP[2]=PacketUtil.decode(data, 44);
peerIP[2]=PacketUtil.decode(data, 40);

peerIP[3]=PacketUtil.decode(data, 48);
peerIP[3]=PacketUtil.decode(data, 44);
}
}

Expand Down

0 comments on commit d7ed4f7

Please sign in to comment.