Hello,
This fixes 'arg list too long' problem when passed to git-ls-files.
Sasha.
This fixes 'arg list too long..' problem with git-ls-files.
Note that second arg list separation loop (with 'git-update-index') is
needed since git-ls-files arguments can be directories.
Signed-off-by: Sasha Khapyorsky <sashak@voltaire.com>
diff --git a/git-svnimport.perl b/git-svnimport.perl
index 6e3a44a..b6799d8 100755
--- a/git-svnimport.perl
+++ b/git-svnimport.perl
@@ -546,23 +546,30 @@ sub commit {
}
}
- if(@old) {
- open my $F, "-|", "git-ls-files", "-z", @old or die $!;
- @old = ();
+ while(@old) {
+ my @o1;
+ if(@old > 55) {
+ @o1 = splice(@old,0,50);
+ } else {
+ @o1 = @old;
+ @old = ();
+ }
+ open my $F, "-|", "git-ls-files", "-z", @o1 or die $!;
+ @o1 = ();
local $/ = "\0";
while(<$F>) {
chomp;
- push(@old,$_);
+ push(@o1,$_);
}
close($F);
- while(@old) {
+ while(@o1) {
my @o2;
- if(@old > 55) {
- @o2 = splice(@old,0,50);
+ if(@o1 > 55) {
+ @o2 = splice(@o1,0,50);
} else {
- @o2 = @old;
- @old = ();
+ @o2 = @o1;
+ @o1 = ();
}
system("git-update-index","--force-remove","--",@o2);
die "Cannot remove files: $?\n" if $?;
-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
| Rafael J. Wysocki | 2.6.28-rc5: Reported regressions from 2.6.27 |
| Kamalesh Babulal | [BUG] 2.6.23-rc3-mm1 - kernel BUG at net/core/skbuff.c:95! |
| Andi Kleen | Re: [git pull] kgdb-light -v8, (was: Re: kgdb in git-x86#mm review) |
| Karl Meyer | PROBLEM: 2.6.23-rc "NETDEV WATCHDOG: eth0: transmit timed out" |
git: | |
| Mirko Stocker | Working with Git and CVS in a team. |
| Junio C Hamano | Re: [PATCH] Teach remote machinery about remotes.default config variable |
| Wink Saville | Resolving conflicts |
| Sam Song | Fwd: [OT] Re: Git via a proxy server? |
| Jerome Santos | sshd.config and AllowUsers |
| Marco Peereboom | Re: What is our ultimate goal?? |
| Will Maier | Re: howto set global environment variable (e.g. PATH, JAVA_HOME) |
| Brandon Lee | DELL PERC 5iR slow performance |
| ackman | RTL8169 driver no longer functioning with 8111b |
| Patrick McHardy | pkt_sched: add DRR scheduler |
| denys | NMI lockup, 2.6.26 release |
| Felix Radensky | RE: e1000e "Detected Tx Unit Hang" |
| Kernel Panic when schedule is called | 43 minutes ago | Linux kernel |
| VPN's on NetBSD | 13 hours ago | NetBSD |
| Why does uClinux 2.6.18 bootup block SuperIO UART IRQs that BIOS configured | 15 hours ago | Linux kernel |
| USB statistics | 16 hours ago | Linux kernel |
| Block Sub System query | 20 hours ago | Linux kernel |
| kernel module to intercept socket creation | 21 hours ago | Linux kernel |
| Image size changing during each build | 22 hours ago | Linux kernel |
| Soft lock bug | 1 day ago | Linux kernel |
| sysctl - dynamic registration problem | 1 day ago | Linux kernel |
| Question on swap as ramdisk partition | 1 day ago | Linux kernel |
