Incorrect file length count in "long name" warning

Please report only one bug per message!

Moderators: white, Hacker, petermad, Stefan2

User avatar
MarcinW
Power Member
Power Member
Posts: 852
Joined: 2012-01-23, 15:58 UTC
Location: Poland

Post by *MarcinW »

UPDATE: still not fully fixed - try to set file name with 256 colons (:::::::::::::::: ...).

You still get the "please remove write protection" message.

Regards
User avatar
Dalai
Power Member
Power Member
Posts: 9352
Joined: 2005-01-28, 22:17 UTC
Location: Meiningen (Südthüringen)

Post by *Dalai »

Well, it seems that invalid characters are checked before the file name length. Makes sense to me. However, the error message needs improvement; it's always been this meaningless - but that's really OT now.

Regards
Dalai
#101164 Personal licence
Ryzen 5 2600, 16 GiB RAM, ASUS Prime X370-A, Win7 x64

Plugins: Services2, Startups, CertificateInfo, SignatureInfo, LineBreakInfo - Download-Mirror
User avatar
MarcinW
Power Member
Power Member
Posts: 852
Joined: 2012-01-23, 15:58 UTC
Location: Poland

Post by *MarcinW »

History.txt wrote:21.05.18 Fixed: When copying/moving/renaming a file, show "Invalid name" error when Windows reports an invalid name or path (error 123 or 161) (32/64)
I just wanted to say that - when you call MoveFile API to set file name to :::::::: - you get error code 123, but the error message is still "please remove write protection" (as it was before) - NOT "Invalid name", as it was intended (and described History.txt). So there must be still some problem with the current implementation.

Regards
User avatar
MarcinW
Power Member
Power Member
Posts: 852
Joined: 2012-01-23, 15:58 UTC
Location: Poland

Post by *MarcinW »

I made a quick research. When entering a proper new name for the file, the MoveFileEx API is called to do its work.

But when entering ::::::: as a file name, MoveFileEx call is not reached - so it has no chance to return error code 123 (which would display the "Invalid name" error).

Instead, some earlier TC code rejects ::::::: as a file name, displaying the "please remove write protection" error (instead of the expected "Invalid name" error).

Regards
Post Reply