evristzam / ndt

Automatically exported from code.google.com/p/ndt
Other
0 stars 0 forks source link

NDTConstants.SRV_QUEUE_TEST_STARTS_NOW misplaced in the Java client. #101

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
By comparing line 2412 
(https://code.google.com/p/ndt/source/browse/trunk/Applet/Tcpbw100.java#2412) 
with other similar parts of the code (e.g., 
https://code.google.com/p/ndt/source/browse/trunk/Applet/Tcpbw100.java#2494), 
it seems to me that 
line 2412 should use
NDTConstants.PROTOCOL_MSG_READ_SUCCESS
instead of
NDTConstants.SRV_QUEUE_TEST_STARTS_NOW

On the other hand, NDTConstants.SRV_QUEUE_TEST_STARTS_NOW should be used at 
line 
https://code.google.com/p/ndt/source/browse/trunk/Applet/Tcpbw100.java#2437.

Note that the changes that I am proposing

1) are consistent with the implementation of the c client.
See https://code.google.com/p/ndt/source/browse/trunk/src/web100clt.c#671 and 
https://code.google.com/p/ndt/source/browse/trunk/src/web100clt.c#691

2) would not change the behavior of the Java client in any way, because 
NDTConstants.PROTOCOL_MSG_READ_SUCCESS == 
NDTConstants.SRV_QUEUE_TEST_STARTS_NOW == 0.

Could you confirm if my suggestions make sense or if I simply misread the code?

Original issue reported on code.google.com by tizi...@google.com on 22 Nov 2013 at 3:27

GoogleCodeExporter commented 9 years ago
I confirm that your reasoning is correct. 

Original comment by jslawin...@soldevelo.com on 22 Nov 2013 at 4:07

GoogleCodeExporter commented 9 years ago
Thanks for the confirmation!

Original comment by tizi...@google.com on 22 Nov 2013 at 4:19

GoogleCodeExporter commented 9 years ago

Original comment by jslawin...@soldevelo.com on 28 Nov 2013 at 8:59

GoogleCodeExporter commented 9 years ago

Original comment by smale...@soldevelo.com on 7 Feb 2014 at 8:49

GoogleCodeExporter commented 9 years ago

Original comment by smale...@soldevelo.com on 7 Feb 2014 at 8:49

GoogleCodeExporter commented 9 years ago
Fix issue with misplaced constants in Java client. Changes are available on 
applet_101 branch. Feel free to review it.

Original comment by smale...@soldevelo.com on 7 Feb 2014 at 12:49

GoogleCodeExporter commented 9 years ago
Commit away

Original comment by AaronMat...@gmail.com on 7 Feb 2014 at 9:29

GoogleCodeExporter commented 9 years ago
Looks good

Original comment by rsanger...@gmail.com on 10 Feb 2014 at 10:04

GoogleCodeExporter commented 9 years ago

Original comment by smale...@soldevelo.com on 10 Feb 2014 at 12:14

GoogleCodeExporter commented 9 years ago

Original comment by skost...@soldevelo.com on 23 Jun 2014 at 5:54