DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=31387>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=31387

TFTPClient.setMaxTimeouts() param check broken

           Summary: TFTPClient.setMaxTimeouts() param check broken
           Product: Commons
           Version: 1.0 Alpha
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: Normal
          Priority: Other
         Component: Net
        AssignedTo: [EMAIL PROTECTED]
        ReportedBy: [EMAIL PROTECTED]


The input check on this method inspects the instance variable it is 
going to set not the input received.

Index: TFTPClient.java
===================================================================
RCS file: /home/cvspublic/jakarta-commons/net/src/java/org/apache/commons/net/
tftp/TFTPClient.java,v
retrieving revision 1.14
diff -u -r1.14 TFTPClient.java
--- TFTPClient.java     29 Jun 2004 04:54:31 -0000      1.14
+++ TFTPClient.java     23 Sep 2004 13:55:24 -0000
@@ -86,7 +86,7 @@
      ***/
     public void setMaxTimeouts(int numTimeouts)
     {
-        if (__maxTimeouts < 1)
+        if (numTimeouts < 1)
             __maxTimeouts = 1;
         else
             __maxTimeouts = numTimeouts;

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to