Ticket UUID: | 454597 | |||
Title: | Limited path size | |||
Type: | Bug | Version: | obsolete: 8.3.2 | |
Submitter: | kofeinik | Created on: | 2001-08-23 14:47:03 | |
Subsystem: | 37. File System | Assigned To: | vincentdarley | |
Priority: | 5 Medium | Severity: | ||
Status: | Closed | Last Modified: | 2001-08-24 23:38:46 | |
Resolution: | Wont Fix | Closed By: | vincentdarley | |
Closed on: | 2001-08-24 16:38:46 | |||
Description: |
Maybe this isn't bug, but annoying feature - under Windows path size for all file operations limited to about 250 characters, as result, i can't work with files, placed in deep directory trees, with path longer than 250 characters. Of course, on pure WinAPI (C/C++) i can work with long paths without any problems. | |||
User Comments: |
vincentdarley added on 2001-08-24 23:38:46:
Logged In: YES user_id=32170 Unless or until new Win32 api's are available/used this bug can't be fixed. I'll add note to this fact to filename.n, and will close the bug (p.s. I don't see a 'maybe' in "Of course, on pure WinAPI (C/C++) i can work with long paths without any problems"). kofeinik added on 2001-08-24 04:56:26: Logged In: YES user_id=286083 Really, under windows there are problems with names of files in length close to boundary 260 characters. I rewrite the test, also have broken off - as was fairly remarked, these problems actually arises at a winapi level. All of an apology for early bugreport, though I have written about "maybe". :) hobbs added on 2001-08-24 01:40:40: Logged In: YES user_id=72656 Thas to be related in some way to an internal 260 (seems like 260 to me) char limit. On Win2K, you can try this: for { set i 100 } { $i < 500 } { incr i } { set str [string replace [string repeat a $i] end-3 end $i] if {[catch {close [open $str w]}]} { puts "stopped at $i, allowed \ [expr {[string length [pwd]]+$i-1}] chars total" break } } For me that returns: stopped at 244, allowed 259 chars total (you have to allow for [pwd] size). I then went into explorer to see if I could edit the file name to be longer - I couldn't! I could remove and add a char, but it wouldn't let me go longer. That indicates a system limit. dgp added on 2001-08-23 22:14:03: Logged In: YES user_id=80530 I think an example of some Tcl code failing to do what you expect would help clarify this report, and help locate what code needs changing. Also, what specific Windows platform are we talking about? vincentdarley added on 2001-08-23 22:13:31: File Added - 9895: pathlength.tcl Logged In: YES user_id=32170 It would have been helpful to have a more precise example of the problem, but fortunately it is easyish to reproduce. The attached script can show at least one bug of this type. It eventually fails with: can't create directory "C:/Apps/dir0.8519/dir0.9923/dir0.1220/dir0.6213/d ir0.5330/dir0.0420/dir0.7874/dir0.5259/dir0.3268/dir0.1379/d ir0.6095/dir0.3286/dir0.3591/dir0.5962/dir0.7668/dir0.2869/d ir0.2434/dir0.3738/dir0.8613/dir0.4409/dir0.5180/dir0.5485/d ir0.6886/dir0.4262/dir0.1771": file name too long % Since you seem to know something of the Win32 API's involved here, Sergey, perhaps you can look at the APIs used (they are in tclWin32dll.c, where either some ascii or unicode api's are loaded into a lookup table, from which they are then called in, say, tclWinFCmd.c or tclWinFile.c) and suggest what is wrong with them. I don't believe Tcl itself has any filename length limitations, so I think the problem could be we are using older Win32 APIs which have such limitations. |
Attachments:
- pathlength.tcl [download] added by vincentdarley on 2001-08-23 22:13:31. [details]