From: Pablo R. (JIRA) <tr...@fi...> - 2013-02-07 19:48:27
|
FBCLIENT.DLL ------------- Key: CORE-4043 URL: http://tracker.firebirdsql.org/browse/CORE-4043 Project: Firebird Core Issue Type: Bug Components: API / Client Library Affects Versions: 2.5.2 Environment: Windows 7 x64 - Delphi 2010 - Firebird 2.5.2 Reporter: Pablo Romero I have a Delphi database application that is currently running on FB 2.5 server. Application was working OK for several years on previous FB versions. I switched to FB 2.5 early when it was released. This year I noticed a couple of cases when there was "INF" value written in double precision field in database. I also noticed, that Delphi Try / Except / End block was not catching EZeroDivide etc. exceptions. This is big problem. Imagine a case like this: var A,B,C: Real; try C := A / B; // B is zero here except C := 0; end Exception is not raised on C calculation and C is calculated as INF "infinity" number. Well: I can change that and check if B is zero and do workaround, but there is Delphi VCL that depends on exception being raised! By default, Delphi sets FPU Control Word to raise exceptions. You can read more about that here: http://qc.embarcadero.com/wc/qcmain.aspx?d=5928 So, when I was looking for DLL that my application loads that disables FPU exceptions, I realised that it is Firebird Client library or its MSVC RTL. Every time you connect to a database, all exceptions are disabled. You execute a query, and all exceptions are disabled. What I found out is that my Delphi application catches exceptions, working ok, if I use FB client from version 1.5 up to version 2.1.4. With Fbclient.dll 2.5 there are problems. ¿Is FB Client that is builded with disabled FPU exceptions catching or is it MSVC RTL?. I dont know if MSVC RTL changed from FB 2.1.4 to FB 2.5 or it is the same. If I set FPU control manualy in my application it works only for a couple of lines, until another "Select..." of code, and it is back disabled again, so this is not a solution. Currently I am using 2.1.4 client to be on the safe side. Regards Pablo Romero Cordoba, Argentina -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://tracker.firebirdsql.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |