> It might help to tell us which compiler and linker flags you are
> already using.
Executable:
C:\lazarus\fpc\3.0.4\bin\i386-win32\fpc.exe
CurrentDirectory:
C:\Users\sita\Documents\lazudf\production\UDF_UTF8\
Parameters:
-B
-Twin64
-Px86_64
-MObjFPC
-Sch
-Xs
-l
-vewnhibq
-FiC:\Users\sita\Docum
On Tue, 7 May 2019 10:54:53 +0200
Massimo Fazzolari wrote:
> Anybody could help me to figure out what's wrong with the
> FPC 64bit compiler? Is there any compile/linker flag that I should
> use?
It might help to tell us which compiler and linker flags you are
already using.
Paul
--
Paul Reev
I tried to compile with FPC 3.0.4 for Win32 and it works. The problems
occurs only on FPC 3.0.4 Win64. I edited the function to log to a file some
debug text as first instruction of the function and it's not invoked, so I
think on Win64 Firebird doesn't even make to call the UDF. Anybody could
help
>
> Do you check returned value for nil?
Yes, this Simple function is just one of a big set of UDFs that we exported
in the same dll/so file. We have been using these functions in production
for more than 10 years. I stumbled upon this issue when I tried to compile
the same working code (without
06.05.2019 14:59, Massimo Fazzolari wrote:
I use this udfmalloc, on windows is defined as:
function udfmalloc(Size: Integer): Pointer; cdecl; external 'ib_util.dll' name
'ib_util_malloc';
Do you check returned value for nil?
BTW, "Integer" is not always right declaration for the argument.
>
> What is in firebird.log ?
Nothing in the firebird.log
How UDF is declared in DB ?
DECLARE EXTERNAL FUNCTION SIMPLE
CSTRING (254)
RETURNS CSTRING (254) FREE_IT
ENTRY_POINT 'Simple' MODULE_NAME 'SitaUdfLib.dll'
How UDF is declared in Pascal ?
function Simple(sz: PChar): PChar; c
06.05.2019 10:48, Massimo Fazzolari wrote:
Hello,
I have an UDF lib compiled with FPC 3.0.4 (Lazarus 2.0.2) that works properly on linux (Ubuntu 18.04 and Firebird 2.5.8.27089) but
Firebird crashes on Windows with this error everytime I invoke any of the user defined functions:
*Error writing
06.05.2019 12:08, Massimo Fazzolari wrote:
There is no code changes to my UDF source code between the version compiled with FPC 2.6.3
(which works on both linux and windows) and FPC 3.0.4 (which doesn't work on Windows, but
works on Linux).
Some bugs (such as wrong calling convention usage)
There is no code changes to my UDF source code between the version compiled
with FPC 2.6.3 (which works on both linux and windows) and FPC 3.0.4 (which
doesn't work on Windows, but works on Linux). My best guess is that there
is some problem at linking time when using FPC 3.0.4 on windows. Somethin
06.05.2019 9:48, Massimo Fazzolari wrote:
Does anybody have any clue what could cause this issue on Windows?
Bug in either your UDF or FPC.
--
WBR, SD.
Firebird-Devel mailing list, web interface at
https://lists.sourceforge.net/lists/listinfo/firebird-devel
Hello,
I have an UDF lib compiled with FPC 3.0.4 (Lazarus 2.0.2) that works
properly on linux (Ubuntu 18.04 and Firebird 2.5.8.27089) but Firebird
crashes on Windows with this error everytime I invoke any of the user
defined functions:
*Error writing data to connection*
The same UDF library work
11 matches
Mail list logo