X-Git-Url: http://git.rot13.org/?p=BackupPC.git;a=blobdiff_plain;f=lib%2FBackupPC%2FPoolWrite.pm;h=d7e37c1a412a25af95bb21e9695fbd9d37de5c22;hp=3934827fc68f3be4ddb91dfbb36b1f375a91c06c;hb=63948b2b693c57faa83050d7590bbf11acc3388c;hpb=3d15da9b2c6de8018c02677549678d6d769234b5 diff --git a/lib/BackupPC/PoolWrite.pm b/lib/BackupPC/PoolWrite.pm index 3934827..d7e37c1 100644 --- a/lib/BackupPC/PoolWrite.pm +++ b/lib/BackupPC/PoolWrite.pm @@ -38,7 +38,7 @@ # Craig Barratt # # COPYRIGHT -# Copyright (C) 2001-2007 Craig Barratt +# Copyright (C) 2001-2009 Craig Barratt # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -56,7 +56,7 @@ # #======================================================================== # -# Version 3.2.0, released 31 Dec 2008. +# Version 3.2.0, released 31 Jul 2010. # # See http://backuppc.sourceforge.net. # @@ -96,9 +96,10 @@ sub new # unlink($fileName) if ( -f $fileName ); if ( $fileName =~ m{(.*)/.+} && !-d $1 ) { - eval { mkpath($1, 0, 0777) }; + my $newDir = $1; + eval { mkpath($newDir, 0, 0777) }; if ( $@ ) { - push(@{$self->{errors}}, "Unable to create directory $1 for $self->{fileName}"); + push(@{$self->{errors}}, "Unable to create directory $newDir for $self->{fileName}"); } } return $self;