Stack overflow in cvt.cpp with invalid DSC from UDF
---------------------------------------------------
Key: CORE-5317
URL: http://tracker.firebirdsql.org/browse/CORE-5317
Project: Firebird Core
Issue Type: Bug
Components: UDF
Affects Versions: 2.5.6
Reporter: Geoff Worboys
Priority: Minor
I've marked this down as a UDF related issue because I don't imagine you should
get invalid DSC from anywhere else.
If a UDF returns an invalid result "by descriptor" (an invalid DSC) then it is
possible for CVT_Move to get called in an attempt to convert the return value.
The conversion fails and calls CVT_conversion_error, which can result in a call
to CVT_Move (trying to convert to the input to ASCII to give a useful message),
but when the DSC is invalid that fails too and so we get infinite recursion and
a stack overflow.
I was experimenting with changing the return dsc_type to 0 (unknown) because
that apparently used to be a way to indicate an error to the server by causing
a conversion error (according to a really old document by Claudio). But all I
get now is a stack overflow.
Only reported as minor because, let's face it, the problem actually lies in the
UDF. But it would be nice if the server would fail gracefully.
--
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
------------------------------------------------------------------------------
What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic
patterns at an interface-level. Reveals which users, apps, and protocols are
consuming the most bandwidth. Provides multi-vendor support for NetFlow,
J-Flow, sFlow and other flows. Make informed decisions using capacity planning
reports.http://sdm.link/zohodev2dev
Firebird-Devel mailing list, web interface at
https://lists.sourceforge.net/lists/listinfo/firebird-devel