Hi good folk -
I've been using the following:
perl 5.8.3,
debugger perl5db.pl version 1.23,
Text::Template version 1.20,

and all goes well if I break inside a template in the debugger:

In file debug.tmpl:
{
debug: $DB::single=1;
$OUT = 'test';
}

When I run a script that processes the template in the debugger I see:

Text::Template::fill_in((eval 36)[/my/test/dir/Text/Template.pm:259]:3):
3:      $OUT = 'test';
  DB<1>

But now I'd like to upgrade to the current version of Text::Template (1.44) to take advantage of taint-checking and bug fixes. But when I try to use v1.44 and the debugger in the same scenario as above, I get this instead:

Text::Template::fill_in(debug.tmpl:3):
3:
  DB<1>

I can't figure out why the next line to be executed in the template doesn't print out. Moreover, the 'l' and 'v' commands don't work either.

All is not completely lost:  'T' still prints useful output:
  DB<1> T
$ = eval 'package Text::Template::GEN0; ;
#line 1 debug.tmpl

debug: $DB::single=1;
$OUT = \'test\';' called from file `/my/test/dir/Text/Template.pm' line 330

But that's certainly not as useful as having the next line printed above the prompt.

I'm not sure where to go from here in figuring out the problem.
Flailing, I tried hardcoding the choice of whether to untaint or not into Text::Template.pm, but that doesn't seem to make any difference. The line that executes the template code in Text::Template is line 319 of v1.44:
    $fi_res = eval $fi_progtext;

but this line doesn't differ between the 2 versions.

Any insight anyone might have would be greatly appreciated.

Thanks very much,
Jay

Reply via email to