[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: `rename-file' with leading spaces in filename
From: |
martin rudalics |
Subject: |
Re: `rename-file' with leading spaces in filename |
Date: |
Wed, 04 Jan 2006 10:43:45 +0100 |
User-agent: |
Mozilla Thunderbird 1.0 (Windows/20041206) |
> Did you actually try that? w32.c:sys_rename jumps through the hoops
> to work around the Windows 9X bugs related to aliases. Perhaps it
> fails in this case, but it would be nice if you could step with a
> debugger through sys_rename and tell where the logic there fails.
I completely fail to understand the logic of this, hence you probably
have to tell me more precisely what to do (I didn't anticipate that this
special part of sys_rename would apply to Windows9_8_ at all).
Suppose my directory "c:/x" contains
FOOBAR~1 11 04.01.06 8:48 foo bar
FOOBAR~ 11 04.01.06 8:47 foo bar~
FOOBAR 10 04.01.06 8:43 foobar
and I try to save some changes in a buffer visiting "foobar".
With `backup-by-copying' non-nil - my standard setting - saving doesn't
pass through sys_rename. With `backup-by-copying' nil saving behaves in
a rather unpredictable way, I never bothered to find out why. Anyway,
from a trace with sys_rename residing at line 2137 of w32.c I got the
following excerpts:
... line 2155:
oldname = 0x22f8af0 "c:/x/foobar"
... line 2178:
o = 0x12ead2d "foobar"
p = 0xd2d675 "foobar"
i = 0
result = 33620403
temp = "c:\\x\\foobar\0\230×Ò\0׺ìÿ°ÖÒ\0\224ÖÒ\0\001\0\0\0\006\0\0\0\004\0\0\200\0\0\0\0\0\0\0\0Ø\032\a\001\0\0\0\0ÿ\v\003Àÿÿÿÿ\037\0\001", '\0' <repeats 25 times>, "\177\003ÿÿ \001ÿÿÿÿÿÿ", '\0' <repeats 14 times>, "ÿÿ", '\0' <repeats 46
times>, "\200Æ\b@", '\0' <repeats 12 times>, "@\237jïØÎ7@<'address@hidden"\002³\001\001\002Ð\001\001\002\220\001\001\002\0\0\0\0\230×Ò\0Ø\032\a\001\177\001\0\0F"...
oldname = 0x12ead28 "c:\\x\\foobar"
... line 2179:
o = 0x12ead2d "foobar"
p = 0xd2d675 "_.foobar.0"
i = 0
result = 33620403
temp = "c:\\x\\_.foobar.0\0׺ìÿ°ÖÒ\0\224ÖÒ\0\001\0\0\0\006\0\0\0\004\0\0\200\0\0\0\0\0\0\0\0Ø\032\a\001\0\0\0\0ÿ\v\003Àÿÿÿÿ\037\0\001", '\0' <repeats 25 times>, "\177\003ÿÿ \001ÿÿÿÿÿÿ", '\0' <repeats 14 times>, "ÿÿ", '\0' <repeats 46
times>, "\200Æ\b@", '\0' <repeats 12 times>, "@\237jïØÎ7@<'address@hidden"\002³\001\001\002Ð\001\001\002\220\001\001\002\0\0\0\0\230×Ò\0Ø\032\a\001\177\001\0\0F"...
oldname = 0x12ead28 "c:\\x\\foobar"
... line 2199:
result = 33620403
temp = "c:\\x\\_.foobar.0\0׺ìÿ°ÖÒ\0\224ÖÒ\0\001\0\0\0\006\0\0\0\004\0\0\200\0\0\0\0\0\0\0\0Ø\032\a\001\0\0\0\0ÿ\v\003Àÿÿÿÿ\037\0\001", '\0' <repeats 25 times>, "\177\003ÿÿ \001ÿÿÿÿÿÿ", '\0' <repeats 14 times>, "ÿÿ", '\0' <repeats 46
times>, "\200Æ\b@", '\0' <repeats 12 times>, "@\237jïØÎ7@<'address@hidden"\002³\001\001\002Ð\001\001\002\220\001\001\002\0\0\0\0\230×Ò\0Ø\032\a\001\177\001\0\0F"...
oldname = 0x12ead28 "c:\\x\\foobar"
Regardless of how `backup-by-copying' is set, "foo bar~" doesn't exist
any more after this:
FOOBAR~1 11 04.01.06 8:48 foo bar
FOOBAR~ 10 04.01.06 8:43 foobar~
FOOBAR 10 04.01.06 8:56 foobar