diff options
author | Phil Mesnier <mesnier_p@ociweb.com> | 2013-07-02 20:54:03 +0000 |
---|---|---|
committer | Phil Mesnier <mesnier_p@ociweb.com> | 2013-07-02 20:54:03 +0000 |
commit | 7f27647a56a86f4a18c941126bd95cc24330a747 (patch) | |
tree | e60afa39b544283ec0665a62a560d9ebf72d2102 /ACE/performance-tests | |
parent | b66d97eae8e39af5890a393b603784afa021d62b (diff) | |
download | ATCD-7f27647a56a86f4a18c941126bd95cc24330a747.tar.gz |
Tue Jul 2 20:52:26 UTC 2013 Phil Mesnier <mesnier_p@ociweb.com>
* contrib/minizip/zip.c:
* performance-tests/UDP/udp_test.cpp:
Minor coverity fixes.
Diffstat (limited to 'ACE/performance-tests')
-rw-r--r-- | ACE/performance-tests/UDP/udp_test.cpp | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/ACE/performance-tests/UDP/udp_test.cpp b/ACE/performance-tests/UDP/udp_test.cpp index 0da5570decf..1c09b94f964 100644 --- a/ACE/performance-tests/UDP/udp_test.cpp +++ b/ACE/performance-tests/UDP/udp_test.cpp @@ -358,13 +358,10 @@ Client::run (void) } } - if (window) - { - window = window * 1000; // convert to nsec. - ndist = (int)((max-min) / window) + 1; - Dist = (u_int *) ACE_OS::calloc (ndist, - sizeof (u_int)); - } + window = window * 1000; // convert to nsec. + ndist = (int)((max-min) / window) + 1; + Dist = (u_int *) ACE_OS::calloc (ndist, + sizeof (u_int)); for (i = 0; i < (ACE_INT32) nsamples; i++) { @@ -591,7 +588,7 @@ ACE_TMAIN (int argc, ACE_TCHAR *argv[]) break; case 'w': window = ACE_OS::atoi (getopt.opt_arg ()); - if (window < 0) + if (window < 2) ACE_ERROR_RETURN ((LM_ERROR, "Invalid window!\n\n"), 1); |