]> Sergey Matveev's repositories - public-inbox.git/commitdiff
nntpd: avoid uninitialized warning
authorEric Wong <e@80x24.org>
Thu, 19 May 2016 08:06:05 +0000 (08:06 +0000)
committerEric Wong <e@80x24.org>
Thu, 19 May 2016 08:06:05 +0000 (08:06 +0000)
Oops, but at least it was mostly harmless, just ugly.

Followup-to: 9bfe40e7a4ac 'nntp: use "newsgroup" instead of "name"''
lib/PublicInbox/NNTPD.pm

index 2c84fb3004f1271702c04a4cfda484b50d8d3386..fc26c5c0b812c18875ae2370b3efbb701b31dc98 100644 (file)
@@ -51,7 +51,7 @@ sub refresh_groups () {
                        push @list, $ng;
                }
        }
-       @list = sort { $a->{name} cmp $b->{name} } @list;
+       @list = sort { $a->{newsgroup} cmp $b->{newsgroup} } @list;
        $self->{grouplist} = \@list;
        # this will destroy old groups that got deleted
        %{$self->{groups}} = %$new;