Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 21 Jan 2009 16:30:33 GMT
From:      Sergey Skvortsov <skv@FreeBSD.org>
To:        FreeBSD-gnats-submit@FreeBSD.org
Cc:        lth@FreeBSD.org
Subject:   ports/130829: [PATCH] devel/p5-IO-Prompt: fix 'Use of uninitialized value in pattern match'
Message-ID:  <200901211630.n0LGUXf0091906@freefall.freebsd.org>
Resent-Message-ID: <200901211640.n0LGe2iR098021@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         130829
>Category:       ports
>Synopsis:       [PATCH] devel/p5-IO-Prompt: fix 'Use of uninitialized value in pattern match'
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Wed Jan 21 16:40:01 UTC 2009
>Closed-Date:
>Last-Modified:
>Originator:     Sergey Skvortsov
>Release:        FreeBSD 7.1-PRERELEASE amd64
>Organization:
>Environment:
System: FreeBSD protey.ru 7.1-PRERELEASE FreeBSD 7.1-PRERELEASE #0: Thu Jan  1 18:06:58 UTC
>Description:

Fix warnings like:

Use of uninitialized value in pattern match (m//) at /usr/local/lib/perl5/site_perl/5.8.9/IO/Prompt.pm line 91.

Added file(s):
- files/patch-Prompt.pm

>How-To-Repeat:

test.pl:
====================
#!/usr/bin/perl -Tw
use strict;
use warnings;

use IO::Prompt;

my $res = prompt( -prompt => "Enter something:");
====================

./test.pl

Use of uninitialized value in pattern match (m//) at /usr/local/lib/perl5/site_perl/5.8.9/IO/Prompt.pm line 91.
Enter something:


>Fix:

--- p5-IO-Prompt-0.99.4_1.patch begins here ---
Index: Makefile
===================================================================
RCS file: /home/pcvs/ports/devel/p5-IO-Prompt/Makefile,v
retrieving revision 1.4
diff -u -u -r1.4 Makefile
--- Makefile	17 Apr 2008 14:25:33 -0000	1.4
+++ Makefile	21 Jan 2009 15:56:22 -0000
@@ -8,6 +8,7 @@
 PORTNAME=	IO-Prompt
 PORTVERSION=	0.99.4
 DISTVERSIONPREFIX=	v
+PORTREVISION=	1
 CATEGORIES=	devel perl5
 MASTER_SITES=	CPAN
 PKGNAMEPREFIX=	p5-
Index: files/patch-Prompt.pm
===================================================================
RCS file: files/patch-Prompt.pm
diff -N files/patch-Prompt.pm
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ files/patch-Prompt.pm	21 Jan 2009 15:56:22 -0000
@@ -0,0 +1,10 @@
+--- Prompt.pm
++++ Prompt.pm
+@@ -88,6 +88,7 @@
+     @data = map { $flags_alias{$_} || $_ } @data;
+     for (my $i = 0 ; $i < @data ; $i++) {
+         local *_ = \($data[$i]);
++	next unless defined $_;
+         if (ref eq 'HASH') {
+             splice @data, $i + 1, 0, %$_;
+         }
--- p5-IO-Prompt-0.99.4_1.patch ends here ---

>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200901211630.n0LGUXf0091906>