On Thu, Feb 19, 2026 at 06:06:26PM +0000, Gavin Smith wrote:
> Here's my attempt at a fix:
>
> diff --git a/tta/C/convert/call_html_perl_function.c
> b/tta/C/convert/call_html_perl_function.c
> index 229fe424e7..816568a821 100644
> --- a/tta/C/convert/call_html_perl_function.c
> +++ b/tta/C/convert/call_html_perl_function.c
> @@ -607,8 +607,9 @@ call_file_id_setting_redirection_file_names (CONVERTER
> *self,
> {
> STRLEN len;
> const char *file_ret = SvPVutf8 (file_sv, len);
> - result_redirection_files[defined_count]
> - = strndup (file_ret, len);
> + result_redirection_files[defined_count] = malloc (len + 1);
> + memcpy (result_redirection_files[defined_count], file_ret,
> len);
> + result_redirection_files[defined_count][len] = '\0';
> defined_count++;
> }
> }
This looks good to me, but as I said in another mail, it more or less
the same as calling perl_only_strndup.
> This compiles cleanly but I haven't run the code (I don't know how to).
It should be called in the t/init_files_tests.t
prepend_number_redirection_file_names test.
--
Pat