Bug 2116592 - Use of uninitialized value $w in numeric gt (>) at /usr/lib64/perl5/vendor_perl/Cyrus/IMAP/Shell.pm line 676.
Summary: Use of uninitialized value $w in numeric gt (>) at /usr/lib64/perl5/vendor_pe...
Keywords:
Status: ASSIGNED
Alias: None
Product: Red Hat Enterprise Linux 9
Classification: Red Hat
Component: cyrus-imapd
Version: 9.0
Hardware: x86_64
OS: Linux
unspecified
low
Target Milestone: rc
: ---
Assignee: Martin Osvald 🛹
QA Contact: František Hrdina
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2022-08-09 01:37 UTC by Ravindra Patil
Modified: 2023-08-15 06:03 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed:
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github cyrusimap cyrus-imapd issues 4184 0 None open cyradm perl warnings on perl v5.34.1 2022-08-11 07:31:22 UTC
Red Hat Issue Tracker RHELPLAN-130550 0 None None None 2022-08-09 01:43:40 UTC

Description Ravindra Patil 2022-08-09 01:37:38 UTC
Description of problem:

On installing cryus-imapd and after runnimg lm (list mailboxes) in cyradm the following warning occurs:

::1> lm
Use of uninitialized value $w in numeric gt (>) at /usr/lib64/perl5/vendor_perl/Cyrus/IMAP/Shell.pm line 676.

The mail boxes are listed and works as expected.

The perl script reporting issue is provided through perl-cyrus

$ rpm -qf /usr/lib64/perl5/vendor_perl/Cyrus/IMAP/Shell.pm
perl-Cyrus-3.4.1-6.el9.x86_64

The code snippet from Shell.pm

# cat /usr/lib64/perl5/vendor_perl/Cyrus/IMAP/Shell.pm

    668   foreach my $mbx (@res) {
    669     $l = $mbx->[0];
    670     if ($mbx->[1] ne '') {
    671       $l .= ' (' . $mbx->[1] . ')';
    672     }
    673     if (defined ($mbx->[3])) {
    674       $l .= ' (' . $mbx->[3] . ')';
    675     }
    676     if (length($l) + 1 > $w) {                  <<< $w is being called or used without being initialised
    677       $w = length($l) + 1;
 

Version-Release number of selected component (if applicable):
perl-Cyrus-3.4.1-6.el9.x86_64

How reproducible:
Use cryadm command and list mailboxes on the server. 

Steps to Reproduce:
1. Install cyrus-imapd, as dependencey perl-Cyrus is installed.
2. Connect using cyradm command.
3. List mailboxes 

Actual results:
- Getting warning in lm command. 

Use of uninitialized value $w in numeric gt (>) at /usr/lib64/perl5/vendor_perl/Cyrus/IMAP/Shell.pm line 676.

Which confuses non-perl programmers. 

Expected results:
- There should not be such warning to avoid any confusion. 

Additional info:


Note You need to log in before you can comment on or make changes to this bug.