From a50b40c3a527d01243f0e4020fba7cb4957ddb14 Mon Sep 17 00:00:00 2001 From: codehelp Date: Sun, 28 Mar 2010 06:40:49 +0000 Subject: [PATCH] prevent uninitiliased variable. git-svn-id: http://emdebian.org/svn/current@6881 563faec7-e20c-0410-992a-a66f704d0ccd --- em_multistrap | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/em_multistrap b/em_multistrap index b99028d..01fd5cc 100755 --- a/em_multistrap +++ b/em_multistrap @@ -160,9 +160,12 @@ $libdir = "var/lib/apt/"; # lists $etcdir = "etc/apt/"; # sources $dpkgdir = "var/lib/dpkg/"; # state -my $ret = mkdir ("$dir") if (not -d "$dir"); -die ("Unable to create directory '$dir'\n") - if ($ret == 0); +if (not -d "$dir") +{ + my $ret = mkdir ("$dir"); + die ("Unable to create directory '$dir' $!\n") + if ($ret == 0); +} $dir = `realpath $dir`; chomp ($dir); $dir .= ($dir =~ m:/$:) ? '' : "/";