Open GoogleCodeExporter opened 9 years ago
Another solution would be to increment pingValue first before sending the Ping
packet and then you can remove the pingValue-1 from the If statement. Java is
probably casting the pingValue-1 result in the if statement into an integer
primitive which makes the test show this: ping.getData() == 32767 with
pingValue-1 == -32769 which doesn't equal each other.
If you implement the solution of incrementing the pingValue first before doing
a send then there should be no casting up in the if statement since the
pingValue-1 in the if statement can be changed to pingValue.
Original comment by RyanLind...@gmail.com
on 9 Feb 2013 at 12:17
Original issue reported on code.google.com by
RyanLind...@gmail.com
on 9 Feb 2013 at 12:05