Coping Dev list.
Carl.
Ignacio Ybarra wrote:
correction - TotalMilliseconds returns as a double so you will need to cast it:
from: (!) elapsed = DateTime.Now.Subtract(start).Milliseconds;to: elapsed =
(int) DateTime.Now.Subtract(start).TotalMilliseconds;
cheers
ig
From: ignacio_yba...@hotmail.com
To: us...@qpid.apache.org
Subject: dotnet client 0.10 - Sync() and Close()
Date: Thu, 10 Dec 2009 13:20:03 +0000
Hi - any chance someone could modify
http://svn.apache.org/viewvc/qpid/trunk/qpid/dotnet/client-010/client/transport/Session.cs
lines 373 and 486 as per below:
from: (!) elapsed = DateTime.Now.Subtract(start).Milliseconds;
to: elapsed = DateTime.Now.Subtract(start).TotalMilliseconds;
The reason for this request is that TimeSpan.Milliseconds will always return a
value between [-999,999].
This means the condition (elapsed < timeout) in lines 368 and 483 will always be true with the default
private const long _timeout = 600000;
(or any timeout values >= 1000) which can lead to an infinite loop when calling
Session.Sync() and Session.Close().
Many thanks
Ig