clone 413873 -1
reassign 413873 userv
retitle -1 Failure to properly save @tag during nested lists
block 413873 by -1
tags -1 + patch
thanks

I have investigated this and concluded that the problem described in
#413873 is caused by a coding error in debiandoc2sgml's Driver.pm.

start_taglist attempts to save the contents of @tag (which is the list
of <tag> elements seen so far in the taglist) in @tags.  However, when
the list of tags is pushed it is merged with the previously pushed
lists, rather than inventing a new array and pushing a reference.

The attached patch fixes this problem.

I'm cloning this bug as there are two things that need to be done:
  * debiandoc-sgml needs to be fixed
  * userv then needs to be bin-NMUd (or no-change source-NMUd)

I have tested this change locally and it seems to fix the problem for
me.

Ian.

--- tools/lib/Format/Driver.pm~ 2007-08-25 06:35:02.000000000 +0100
+++ tools/lib/Format/Driver.pm  2007-09-23 22:26:49.000000000 +0100
@@ -665,7 +665,7 @@
     $is_footnote = 0;
     push( @list_type, $list_type );
     $list_type = "taglist";
-    push( @tags, @tag );
+    push( @tags, [ @tag ] );
     @tag = ();
     $indent_level++ if $indent_level;
     push_output( 'string' );
@@ -676,7 +676,7 @@
     $taglist =~ s/\s+$//;
     &{$Format."::"._output_taglist}( "$taglist\n", pop( @p_length ) );
     $indent_level-- if $indent_level > 1;
-    @tag = pop( @tags );
+    @tag = @{ pop( @tags ) };
     $is_footnote = pop( @is_footnote );
     $list_type = pop( @list_type );
     $was_compact = $is_compact;

Reply via email to