Subject UDF memory allocation?
Author jarkkosoikkeli

If you pass CSTRING(256) to substr-function. Is it sure that
Interbase/Firebird has allocated 256 bytes for that string so that
writing ending '\0' past the end of the string, but within 256 bytes,
is fine?

extern "C" char * __stdcall substr(char * str, int const * start, int
const * len) {

str[*start + *len] = '\0';
return &str[*start];