From: Rob H. <for...@us...> - 2001-12-22 22:01:57
|
Update of /cvsroot/sandweb/sandweb/lib/SandWeb In directory usw-pr-cvs1:/tmp/cvs-serv26931/lib/SandWeb Modified Files: File.pm Log Message: better debugging and error reporting when a file can't be removed by the user. Index: File.pm =================================================================== RCS file: /cvsroot/sandweb/sandweb/lib/SandWeb/File.pm,v retrieving revision 1.26 retrieving revision 1.27 diff -U2 -r1.26 -r1.27 --- File.pm 2001/12/21 01:12:47 1.26 +++ File.pm 2001/12/22 22:01:54 1.27 @@ -192,8 +192,14 @@ my $filename = $self->{'filename'}; my $log = $self->{'log_obj'}; + my $return; $log->debug("removing file : $location/$filename"); - my $return = unlink("$location/$filename" ); + if ( unlink("$location/$filename") ) { + $return = 1; + } else { + $log->debug("could not remove $location/$filename : $!"); + $return = 0; + } return $return; |