[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

RE: svn command line client 1.8.8 - Error: file name or extension is too long

From: Geoff Field <Geoff_Field_at_aapl.com.au>
Date: Mon, 15 Sep 2014 09:38:29 +1000

> On Fri, Sep 12, 2014 at 11:29:37AM +0200,
> Milan_Plancik_at_swissre.com wrote:
> > Dear team,
> >
> > I tried to commit my changes with following error message:
> >
> > Error:Cannot run program
> "C:\srdev\tool\SVN_CLIENT_1.8.8\svn.exe" (in
> > directory
> >
> "C:\Users\S3F96Q\work\sources\g10ct\SR_G10_CT\modules\sr-g10-c
> t-batch-xd\src\main\resources"):
> > CreateProcess error=206, The filename or extension is too long
> >
> > This file in its path is far away from the longest name in
> project and
> > I only changed the content of its file (did not changed the path or
> > file name). This error prevents me to commit my changes. I
> also tried
> > to checkout it from scratch, so that path changed to:
> >
> C:\work\sources\g10ct\SR_G10_CT\modules\sr-g10-ct-batch-xd\src\main\re
> > sources,
> > but id did not help.
> >
> > Then I tried to commit changes in chunks (I did not change
> any path or
> > file name), which finally worked. I had 285 files to commit.
> >
> > 1. Is it bug? At least message does not correspond to real error 2.
> > Can it be configurable (the max file count to commit or
> some buffer)?
> > (How?)
> > 3. Is it fixed in some newer version?
> >
> > Thank you
> > With regards
> >
> > Milan Plancik
>
> IIRC this is a limitation of windows.

Yes, there is such a limitation of Windows. I've encountered it before in other applications. There's a known issue with paths over 260 characters long, INCLUDING the drive letter, the colon AND the terminating NUL. See this MSDN article:
http://msdn.microsoft.com/en-us/library/aa365247(v=vs.85).aspx#maxpath

If you prepend the string '\\?\' to the path, it's meant to allow 32,767 Unicode characters of path name. We've found, however, that some languages (such as National Instruments' LabVIEW up to version 8.6 at least) don't allow this.

There are two approaches available in this case:
1) Shorten your path names.
2) Use the DOS subst command to create a new virtual drive starting at an appropriate place in the tree (preferably the directory where the .svn directory resides). It would be something like "SUBST Z: C:\work\sources\g10ct" When you're done, you can then do "SUBST Z: /D" to delete it.

However, please note that Milan finally mannaged to commit all the files by doing them in smaller batches. That would seem to indicate some other issue.

> Passing absolute paths on the command line should work around it.

Probably not, given what I've just discussed.
 
> BTW, please try to avoid posting disclaimers like the one
> below to public mailing list. See
> http://producingoss.com/en/communications.html#face

Some of us are subject to the whims and caprices of a corporate IT department (and their bosses). I know I am. We can't avoid the disclaimers if we're using our work emails.

Regards,

Geoff

-- 
Apologies for the auto-generated legal boilerplate added by our IT department:
- The contents of this email, and any attachments, are strictly private
and confidential.
- It may contain legally privileged or sensitive information and is intended
solely for the individual or entity to which it is addressed.
- Only the intended recipient may review, reproduce, retransmit, disclose,
disseminate or otherwise use or take action in reliance upon the information
contained in this email and any attachments, with the permission of
Australian Arrow Pty. Ltd.
- If you have received this communication in error, please reply to the sender
immediately and promptly delete the email and attachments, together with
any copies, from all computers.
- It is your responsibility to scan this communication and any attached files
for computer viruses and other defects and we recommend that it be
subjected to your virus checking procedures prior to use.
- Australian Arrow Pty. Ltd. does not accept liability for any loss or damage
of any nature, howsoever caused, which may result
directly or indirectly from this communication or any attached files. 
Received on 2014-09-15 01:39:40 CEST

This is an archived mail posted to the Subversion Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.