activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From qbeardn <>
Subject AbstractQueuedSynchronizer.cpp bug/typo
Date Sat, 17 Mar 2012 19:33:03 GMT

testing the ActiveMQ CPP trunk in the hope of resolving failover
difficulties, I spotted something in the source code. 

lines 752 and 1056 are both statements 
    long now = System::nanoTime(); 
while System::nanoTime() returns a long long. 

I.e., it tosses the top 32 bits (on my platform).  Subsequently there is a
subtraction of now from lastTime which really is a long long and so the
first time those statements are executed (now - lastTime) is a very large
negative number.


View this message in context:
Sent from the ActiveMQ - Dev mailing list archive at

View raw message