From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Carlos
Sent: Friday, December 14, 2007 12:24 PM
To: For users and developers of the Firebird .NET providers
Subject: Re: [Firebird-net-provider] Faulty GdsConnection::NextOperation
Hello:
Nah, not a complete one. The fault is a bit random, and you need a
lengthy dataset to stumble across it (I can't post you our customer database :).
without a test case it's going to be hard difficult to solve the problem,
Yes, I can understand that. But at the same time, the problem is use of
System.Net.Sockets.NetworkStream.Read without checking if there is data
available, which, according to the documentation
http://msdn2.microsoft.com/en-us/library/system.net.sockets.networkstream.read(VS.71).aspx,
will block until data is available.
what si the character set of the database and the one you are using in the
connection string
WIN 1252 (both)
the callstack when the fault occurs is like this (suddenly I am unsure if my
hotfix fixes anything, or if I just have been lucky for a while)
ntdll.dll!7c90eb94()
[Frames below may be incorrect and/or missing, no symbols loaded for
ntdll.dll]
ntdll.dll!7c90e9c0()
mswsock.dll!71a54033()
mswsock.dll!71a557c9()
ntdll.dll!7c90d8ef()
mswsock.dll!71a55908()
[Managed to Native Transition]
System.dll!System.Net.Sockets.Socket.Receive(byte[] buffer =
{byte[4096]}, int offset = 0, int size, System.Net.Sockets.SocketFlags
socketFlags = None, out System.Net.Sockets.SocketError errorCode = Success) +
0x139 bytes
System.dll!System.Net.Sockets.Socket.Receive(byte[] buffer, int
offset, int size, System.Net.Sockets.SocketFlags socketFlags) + 0x1d bytes
System.dll!System.Net.Sockets.NetworkStream.Read(byte[] buffer, int
offset, int size) + 0x78 bytes
mscorlib.dll!System.IO.BufferedStream.Read(byte[] array = {byte[8]},
int offset = 0, int count = 4) + 0xc3 bytes
>
> FirebirdSql.Data.FirebirdClient.dll!FirebirdSql.Data.Client.Gds.XdrStream.Read(byte[]
> buffer = {byte[8]}, int offset = 0, int count = 4) Line 188 + 0x17 bytes
> C#
FirebirdSql.Data.FirebirdClient.dll!FirebirdSql.Data.Client.Gds.XdrStream.ReadInt32()
Line 295 + 0x13 bytes C#
FirebirdSql.Data.FirebirdClient.dll!FirebirdSql.Data.Client.Gds.GdsConnection.NextOperation()
Line 169 + 0xc bytes C#
FirebirdSql.Data.FirebirdClient.dll!FirebirdSql.Data.Client.Gds.GdsDatabase.NextOperation()
Line 632 + 0xa bytes C#
FirebirdSql.Data.FirebirdClient.dll!FirebirdSql.Data.Client.Gds.GdsStatement.Fetch()
Line 415 + 0xd bytes C#
FirebirdSql.Data.FirebirdClient.dll!FirebirdSql.Data.FirebirdClient.FbCommand.Fetch()
Line 655 + 0xe bytes C#
FirebirdSql.Data.FirebirdClient.dll!FirebirdSql.Data.FirebirdClient.FbDataReader.Read()
Line 248 + 0xc bytes C#
konverter.exe!konverter.Window1.select_and_export(string sql =
"SELECT IIF( M.Id < 100000, M.Id + 102000, M.Id ) AS \"Kundenummer\", Navn AS
\"Navn\", COALESCE( Postadresse, '' ) AS \"Adresse\", '' AS \"Adressefelt2\",
COALESCE( Postnummer, '' ) AS \"Postnr\", COALESCE( Poststed, '' ) AS
\"Poststed\", COALESCE( Telefon, '' ) AS \"Telefon\", COALESCE( Faks, '' ) AS
\"Telefaks\", COALESCE( Mobil, '' ) AS \"Mobil\", COALESCE( Epostadresse, '' )
AS \"Email\", COALESCE( Organisasjonsnummer, '' ) AS \"Organisasjonsnr\",
COALESCE( Betalingsbetingelse, '' ) AS \"Kredittdager\", COALESCE(
MF.Kredittgrense, '' ) AS \"Kredittgrense\", '' AS \"Selgernr\", '' AS
\"Kundekategori\", '' AS \"Kommentarer\", COALESCE( Bankkontonummer, '' ) AS
\"Gironummer\", '' AS \"Sist oppdatert\" FROM Motpart M JOIN MotpartFaktura MF
ON MF.Motpartkategori = 'K' AND MF.Id = M.Id JOIN MotpartElektronisk ME ON
ME.Motpartkategori = 'K' AND ME.Id = M.Id WHERE M.Motpartkategori = 'K' AND
Datoslettet IS NULL AND EXISTS( SELECT * FROM Reskontro R WHERE
R.Motpartkategori = 'K' AND R.Motpartid = M.Id )", string path =
"c:\\work\\data\\kunder.txt") Line 48 + 0xa bytes C#
konverter.exe!konverter.Window1.kunder_Click(object sender =
{System.Windows.Controls.Button}, System.Windows.RoutedEventArgs e =
{System.Windows.RoutedEventArgs}) Line 112 + 0xf bytes C#
PresentationCore.dll!System.Windows.RoutedEventHandlerInfo.InvokeHandler(object
target, System.Windows.RoutedEventArgs routedEventArgs) + 0x56 bytes
PresentationCore.dll!System.Windows.EventRoute.InvokeHandlersImpl(object source
= {System.Windows.Controls.Button}, System.Windows.RoutedEventArgs args =
{System.Windows.RoutedEventArgs}, bool reRaised = false) + 0x10f bytes
PresentationCore.dll!System.Windows.UIElement.RaiseEventImpl(System.Windows.RoutedEventArgs
args = {System.Windows.RoutedEventArgs}) + 0xa2 bytes
PresentationCore.dll!System.Windows.UIElement.RaiseEvent(System.Windows.RoutedEventArgs
e) + 0x19 bytes
PresentationFramework.dll!System.Windows.Controls.Button.OnClick() +
0x70 bytes
PresentationFramework.dll!System.Windows.Controls.Primitives.ButtonBase.OnMouseLeftButtonUp(System.Windows.Input.MouseButtonEventArgs
e) + 0x77 bytes
PresentationCore.dll!System.Windows.UIElement.OnMouseLeftButtonUpThunk(object
sender, System.Windows.Input.MouseButtonEventArgs e) + 0x6c bytes
PresentationCore.dll!System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(System.Delegate
genericHandler, object genericTarget) + 0x31 bytes
PresentationCore.dll!System.Windows.RoutedEventArgs.InvokeHandler(System.Delegate
handler, object target) + 0x27 bytes
PresentationCore.dll!System.Windows.RoutedEventHandlerInfo.InvokeHandler(object
target, System.Windows.RoutedEventArgs routedEventArgs) + 0x68 bytes
PresentationCore.dll!System.Windows.EventRoute.InvokeHandlersImpl(object source
= {System.Windows.Controls.Button}, System.Windows.RoutedEventArgs args =
{System.Windows.Input.MouseButtonEventArgs}, bool reRaised = true) + 0x10f
bytes
PresentationCore.dll!System.Windows.UIElement.ReRaiseEventAs(System.Windows.RoutedEventArgs
args = {System.Windows.Input.MouseButtonEventArgs}, System.Windows.RoutedEvent
newEvent) + 0x156 bytes
PresentationCore.dll!System.Windows.UIElement.OnMouseUpThunk(object
sender, System.Windows.Input.MouseButtonEventArgs e) + 0x91 bytes
PresentationCore.dll!System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(System.Delegate
genericHandler, object genericTarget) + 0x31 bytes
PresentationCore.dll!System.Windows.RoutedEventArgs.InvokeHandler(System.Delegate
handler, object target) + 0x27 bytes
PresentationCore.dll!System.Windows.RoutedEventHandlerInfo.InvokeHandler(object
target, System.Windows.RoutedEventArgs routedEventArgs) + 0x68 bytes
PresentationCore.dll!System.Windows.EventRoute.InvokeHandlersImpl(object source
= {System.Windows.Controls.Button}, System.Windows.RoutedEventArgs args =
{System.Windows.Input.MouseButtonEventArgs}, bool reRaised = false) + 0x10f
bytes
PresentationCore.dll!System.Windows.UIElement.RaiseEventImpl(System.Windows.RoutedEventArgs
args = {System.Windows.Input.MouseButtonEventArgs}) + 0xa2 bytes
PresentationCore.dll!System.Windows.UIElement.RaiseEvent(System.Windows.RoutedEventArgs
args = {System.Windows.Input.MouseButtonEventArgs}, bool trusted) + 0x43 bytes
PresentationCore.dll!System.Windows.Input.InputManager.ProcessStagingArea() +
0x200 bytes
PresentationCore.dll!System.Windows.Input.InputManager.ProcessInput(System.Windows.Input.InputEventArgs
input) + 0x5e bytes
PresentationCore.dll!System.Windows.Input.InputProviderSite.ReportInput(System.Windows.Input.InputReport
inputReport) + 0x64 bytes
PresentationCore.dll!System.Windows.Interop.HwndMouseInputProvider.ReportInput(System.IntPtr
hwnd, System.Windows.Input.InputMode mode, int timestamp,
System.Windows.Input.RawMouseActions actions, int x, int y, int wheel) + 0x32e
bytes
PresentationCore.dll!System.Windows.Interop.HwndMouseInputProvider.FilterMessage(System.IntPtr
hwnd, int msg = 514, System.IntPtr wParam = 0, System.IntPtr lParam = 2424888,
ref bool handled = false) + 0x242 bytes
PresentationCore.dll!System.Windows.Interop.HwndSource.InputFilterMessage(System.IntPtr
hwnd = 1117312, int msg = 514, System.IntPtr wParam = 0, System.IntPtr lParam
= 2424888, ref bool handled = false) + 0x76 bytes
WindowsBase.dll!MS.Win32.HwndWrapper.WndProc(System.IntPtr hwnd =
1117312, int msg = 514, System.IntPtr wParam = 0, System.IntPtr lParam =
2424888, ref bool handled = false) + 0x87 bytes
WindowsBase.dll!MS.Win32.HwndSubclass.DispatcherCallbackOperation(object o) +
0x62 bytes
WindowsBase.dll!System.Windows.Threading.ExceptionWrapper.InternalRealCall(System.Delegate
callback = {Method = Cannot evaluate expression because a native frame is on
top of the call stack.}, object args =
{MS.Win32.HwndSubclass.DispatcherOperationCallbackParameter}, bool
isSingleParameter = true) + 0x4a bytes
WindowsBase.dll!System.Windows.Threading.ExceptionWrapper.TryCatchWhen(object
source = {System.Windows.Threading.Dispatcher}, System.Delegate callback,
object args, bool isSingleParameter, System.Delegate catchHandler = null) +
0x3f bytes
WindowsBase.dll!System.Windows.Threading.Dispatcher.InvokeImpl(System.Windows.Threading.DispatcherPriority
priority, System.TimeSpan timeout, System.Delegate method, object args, bool
isSingleParameter) + 0x14f bytes
WindowsBase.dll!System.Windows.Threading.Dispatcher.Invoke(System.Windows.Threading.DispatcherPriority
priority, System.Delegate method, object arg) + 0x3d bytes
WindowsBase.dll!MS.Win32.HwndSubclass.SubclassWndProc(System.IntPtr
hwnd = 1117312, int msg = 514, System.IntPtr wParam = 0, System.IntPtr lParam =
2424888) + 0x1e0 bytes
[Native to Managed Transition]
user32.dll!7e418734()
user32.dll!7e418734()
user32.dll!7e418734()
user32.dll!7e418734()
user32.dll!7e418816()
user32.dll!7e4189cd()
[Managed to Native Transition]
WindowsBase.dll!System.Windows.Threading.Dispatcher.PushFrameImpl(System.Windows.Threading.DispatcherFrame
frame = {System.Windows.Threading.DispatcherFrame}) + 0x144 bytes
WindowsBase.dll!System.Windows.Threading.Dispatcher.PushFrame(System.Windows.Threading.DispatcherFrame
frame) + 0x83 bytes
WindowsBase.dll!System.Windows.Threading.Dispatcher.Run() + 0x75
bytes
PresentationFramework.dll!System.Windows.Application.RunInternal(System.Windows.Window
window) + 0x78 bytes
PresentationFramework.dll!System.Windows.Application.Run(System.Windows.Window
window) + 0x29 bytes
PresentationFramework.dll!System.Windows.Application.Run() + 0x16
bytes
konverter.exe!konverter.App.Main() + 0x4c bytes C#
mscoree.dll!79005bf5()
kernel32.dll!7c816fd7()
-------------------------------------------------------------------------
SF.Net email is sponsored by:
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services
for just about anything Open Source.
http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace
_______________________________________________
Firebird-net-provider mailing list
Firebird-net-provider@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/firebird-net-provider