commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 12841] New: - GenericObjectPool unused variable and unused synchronized block
Date Fri, 20 Sep 2002 01:25:48 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=12841>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=12841

GenericObjectPool unused variable and unused synchronized block

           Summary: GenericObjectPool unused variable and unused
                    synchronized block
           Product: Commons
           Version: Nightly Builds
          Platform: Other
        OS/Version: Other
            Status: NEW
          Severity: Normal
          Priority: Other
         Component: Pool
        AssignedTo: commons-dev@jakarta.apache.org
        ReportedBy: rleland@apache.org


In Evictor.run()
First off sleeptime is never used.
Secondly I see no reason for a syncronized block here,
even if sleeptime was used.

   long sleeptime = 0L;
   synchronized(GenericObjectPool.this) {
      sleeptime = _timeBetweenEvictionRunsMillis;
   }
   try {
      Thread.currentThread().sleep(_timeBetweenEvictionRunsMillis);
   } catch(Exception e) {
       ; // ignored
   }

--
To unsubscribe, e-mail:   <mailto:commons-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:commons-dev-help@jakarta.apache.org>


Mime
View raw message