Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarius Storm-Olsen <marius@trolltech.com>2007-07-13 16:39:05 +0400
committerShawn O. Pearce <spearce@spearce.org>2007-07-15 06:47:14 +0400
commit48b4c3d5ab1610c6dc0198fe94334d78e8a82e16 (patch)
treede029228b82144bbc8f09d56ab5408b52f990bec /contrib/fast-import
parentc7bd55028ff463fa0162bffb35ac519beb462ca5 (diff)
Fix git-p4 on Windows to not use the Posix sysconf function.
Add condition for Windows, since it doesn't support the os.sysconf module. We hardcode the commandline limit to 2K, as that should work on most Windows platforms. Signed-off-by: Marius Storm-Olsen <marius@trolltech.com> Acked-by: Simon Hausmann <simon@lst.de> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Diffstat (limited to 'contrib/fast-import')
-rwxr-xr-xcontrib/fast-import/git-p46
1 files changed, 5 insertions, 1 deletions
diff --git a/contrib/fast-import/git-p4 b/contrib/fast-import/git-p4
index 54a05eb99c..d877150f41 100755
--- a/contrib/fast-import/git-p4
+++ b/contrib/fast-import/git-p4
@@ -717,7 +717,11 @@ class P4Sync(Command):
# POSIX says it's 4096 bytes, default for Linux seems to be 130 K.
# and all OS from the table below seems to be higher than POSIX.
# See http://www.in-ulm.de/~mascheck/various/argmax/
- argmax = min(4000, os.sysconf('SC_ARG_MAX'))
+ if (self.isWindows):
+ argmax = 2000
+ else:
+ argmax = min(4000, os.sysconf('SC_ARG_MAX'))
+
chunk = ''
filedata = []
for i in xrange(len(files)):