]> git.vpit.fr Git - perl/modules/rgit.git/blobdiff - lib/App/Rgit/Repository.pm
Only apply abs_path() to paths that are either relative or that contains ..
[perl/modules/rgit.git] / lib / App / Rgit / Repository.pm
index ec08d4b45e316c235e5b851fbc852f9beb1ff1eb..c340942a820487e1df2650270a1255b423e45b43 100644 (file)
@@ -3,10 +3,12 @@ package App::Rgit::Repository;
 use strict;
 use warnings;
 
-use Cwd        (); # cwd, abs_path
+use Cwd        (); # cwd
 use File::Spec (); # canonpath, catdir, splitdir, abs2rel
 use POSIX      (); # WIFEXITED WEXITSTATUS WIFSIGNALED WTERMSIG SIGINT SIGQUIT
 
+use App::Rgit::Utils (); # abs_path
+
 my ($WIFEXITED, $WEXITSTATUS, $WIFSIGNALED, $WTERMSIG);
 
 BEGIN {
@@ -55,7 +57,7 @@ sub new {
 
  my $dir = $args{dir};
  if (defined $dir) {
-  $dir = Cwd::abs_path($dir);
+  $dir = App::Rgit::Utils::abs_path($dir);
  } else {
   $dir = Cwd::cwd;
  }