Hi Eric,

Thanks for having a look at my patch.

On Fri, Aug 10, 2012 at 12:18:48AM +0300, Eric Pozharski wrote:
> Guys, you really must take some perl courses.

Even though this statement is probably correct (at least in my case),
your criticism is in no way constructive.

> -    while( readdir CATDIR )
> +    while( $_ = readdir CATDIR )

The way I used readdir is given as an example in perldoc perlfunc
/readdir.

>> opendir(my $dh, $some_dir) || die;
>> while(readdir $dh) {
>>     print "$some_dir/$_\n";
>> }
>> closedir $dh;

So really what is wrong here? Looking further in perldoc.

>> As of Perl 5.11.2 you can use a bare "readdir" in a "while" loop,
>> which will set $_ on every iteration.

Ah. So which perl version are we running on squeeze? An older version.
So there are two options to tackle this. A versioned perl dependency or
your diff.

Next time, when you report such an issue, please state that what you
experience is an upgrade failure from squeeze. The way you presented the
issue completely hides the root cause and presents a workaround in an
arrogant way.

I think that a versioned perl dependency is the safer fix, because it
eliminates other (yet unknown) issues of the same kind as well.

Helmut
diff -Nru sgml-base-1.26+nmu4/debian/changelog 
sgml-base-1.26+nmu5/debian/changelog
--- sgml-base-1.26+nmu4/debian/changelog        2012-08-26 12:29:36.000000000 
+0200
+++ sgml-base-1.26+nmu5/debian/changelog        2012-08-27 21:24:37.000000000 
+0200
@@ -1,3 +1,12 @@
+sgml-base (1.26+nmu5) unstable; urgency=low
+
+  * Non-maintainer upload.
+  * Raise perl dependency to avoid upgrade failures from squeeze. The way we
+    use readdir does not work on squeeze.
+    http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=678902#62
+
+ -- Helmut Grohne <hel...@subdivi.de>  Mon, 27 Aug 2012 21:23:15 +0200
+
 sgml-base (1.26+nmu4) unstable; urgency=low
 
   * Non-maintainer upload.
diff -Nru sgml-base-1.26+nmu4/debian/control sgml-base-1.26+nmu5/debian/control
--- sgml-base-1.26+nmu4/debian/control  2012-08-26 12:29:36.000000000 +0200
+++ sgml-base-1.26+nmu5/debian/control  2012-08-27 21:25:09.000000000 +0200
@@ -11,7 +11,7 @@
 Priority: optional
 Architecture: all
 Conflicts: sgml-data (<= 0.02), sgmltools-2 (<= 2.0.2-4)
-Depends: ${perl:Depends}
+Depends: ${perl:Depends}, perl (>= 5.11.2)
 Pre-Depends: dpkg (>= 1.16.4)
 Suggests: sgml-base-doc
 Description: SGML infrastructure and SGML catalog file support

Reply via email to