git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Big path on git add file [windows bug]
@ 2015-09-16  8:01 Alexey Kasyanchuk
  2015-09-16  9:40 ` Johannes Schindelin
  0 siblings, 1 reply; 2+ messages in thread
From: Alexey Kasyanchuk @ 2015-09-16  8:01 UTC (permalink / raw)
  To: git

I tried add one of node.js module to git project. But add operation failed:

libgit2 returned: Invalid path for filesystem
'E:/Projects/vsteams/node_modules/gulp-imagemin/node_modules/imagemin/node_modules/imagemin-gifsicle/node_modules/gifsicle/node_modules/bin-build/node_modules/decompress/node_modules/decompress-tar/node_modules/strip-dirs/node_modules/is-natural-number/is-natural-number-cjs.js':
Data area passed to a system call is too small.

Is this windows problem or problem with libgit2 realization on windows
(windows 7 by the way)? It looked like problem with big system path
(276 symbols). May be some sulution for this?

Version: Git-2.5.2.2-64-bit

-- 
Best regards,
Alexey Kasyanchuk
C/C++ Developer


Skype: degitx
mobile: +375295777373

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Big path on git add file [windows bug]
  2015-09-16  8:01 Big path on git add file [windows bug] Alexey Kasyanchuk
@ 2015-09-16  9:40 ` Johannes Schindelin
  0 siblings, 0 replies; 2+ messages in thread
From: Johannes Schindelin @ 2015-09-16  9:40 UTC (permalink / raw)
  To: Alexey Kasyanchuk; +Cc: git

Hi Alexey,

On 2015-09-16 10:01, Alexey Kasyanchuk wrote:
> I tried add one of node.js module to git project. But add operation failed:
> 
> libgit2 returned: Invalid path for filesystem
> 'E:/Projects/vsteams/node_modules/gulp-imagemin/node_modules/imagemin/node_modules/imagemin-gifsicle/node_modules/gifsicle/node_modules/bin-build/node_modules/decompress/node_modules/decompress-tar/node_modules/strip-dirs/node_modules/is-natural-number/is-natural-number-cjs.js':
> Data area passed to a system call is too small.

It is indeed too small for normal operations (MAX_PATH is somewhere around 248). However, as far as I know, libgit2 has internal code to convert the path into a form that the Win32 API can handle.

> Is this windows problem or problem with libgit2 realization on windows
> (windows 7 by the way)? It looked like problem with big system path
> (276 symbols). May be some sulution for this?

Yes, there is a sulution for this. But it is unclear whether you have that already or not because you were a little parsimonious with information. For example, I have no idea which libgit2 version you use, in which context, what program you use to call libgit2, etc.

So I am left guessing, which is a little bit inefficient.

In any case, the work-around for the issue you described is in https://github.com/libgit2/libgit2/commit/cceae9a25d0bed8b00f4981e051d5f380ef54401 which is part of v0.22.1.

> Version: Git-2.5.2.2-64-bit

No, that is not the correct version. This looks like the current Git for Windows version, but the error you reported is clearly a libgit2 error message. And that Git for Windows version contains no libgit2 at all.

Please clarify. You might want to err on the side of verbosity to avoid unnecessary back-and-forth.

Ciao,
Johannes

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2015-09-16  9:40 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-09-16  8:01 Big path on git add file [windows bug] Alexey Kasyanchuk
2015-09-16  9:40 ` Johannes Schindelin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).