summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: bdc4204)
raw | patch | inline | side by side (parent: bdc4204)
author | Michael J. Kiwala <mkiwala@genome.wustl.edu> | |
Tue, 1 Jun 2010 21:24:57 +0000 (16:24 -0500) | ||
committer | Eric Wong <normalperson@yhbt.net> | |
Thu, 3 Jun 2010 20:51:41 +0000 (20:51 +0000) |
Avoid attempts to stat() the contents of '', which could happen
when the root directory is empty. Additionally, remove the
unnecessary '_' stat optimization since it was confusing and
possibly throwing off the non-existent case.
[ew: fixed indentation, rewrote commit message]
Acked-by: Eric Wong <normalperson@yhbt.net>
Signed-off-by: Michael J. Kiwala <mkiwala@genome.wustl.edu>
when the root directory is empty. Additionally, remove the
unnecessary '_' stat optimization since it was confusing and
possibly throwing off the non-existent case.
[ew: fixed indentation, rewrote commit message]
Acked-by: Eric Wong <normalperson@yhbt.net>
Signed-off-by: Michael J. Kiwala <mkiwala@genome.wustl.edu>
git-svn.perl | patch | blob | history |
diff --git a/git-svn.perl b/git-svn.perl
index b3b6964f95976ba885a277de9d463a2443dd3147..09c4ca56f0c9af9c6ff49d3b3a197a8e30602520 100755 (executable)
--- a/git-svn.perl
+++ b/git-svn.perl
foreach my $d (sort keys %empty_dirs) {
$d = uri_decode($d);
$d =~ s/$strip//;
+ next unless length($d);
next if -d $d;
- if (-e _) {
+ if (-e $d) {
warn "$d exists but is not a directory\n";
} else {
print "creating empty directory: $d\n";