EMULAB Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

The new forum is online, hope you enjoy it!

Pages: [1]   Go Down

Author Topic: Filename trailing dots cut-off  (Read 930 times)

newuzer

  • Member
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 20
  • Operating System:
  • Windows NT 10.0 Windows NT 10.0
  • Browser:
  • Firefox 81.0 Firefox 81.0
    • View Profile
Filename trailing dots cut-off
« on: 09 October 2020, 16:03 »

Hi Roman,

MAME 0.225 Software Lists CHDs, pc98_cd.xml

Code: [Select]
<software name="toshin2s">
<disk name="toushin toshi ii - soshite, sorekara..." sha1="10ae6ad7d25f19f4af5dc51953c733496b14b5b2" />

Results in "toushin toshi ii - soshite, sorekara.chd".
If renamed according to the XML, clrmamepro insists on renaming it back.
Code: [Select]
Toushin Toshi II - Soshite, Sorekara... [folder: toshin2s - size: 0]
wrong name: E:\mamesecret\MAME-Software-List-CHDs\MAME 0.225 Software List CHDs (merged)\pc98_cd\toshin2s\toushin toshi ii - soshite, sorekara....chd [wrong: toushin toshi ii - soshite, sorekara....chd] [right: toushin toshi ii - soshite, sorekara.chd]

I agree, it's a nasty label ;)
I've therefor also consulted MAMEdev to look at the label name (and similar ones).
Is it (to your knowledge) a convention that trailing dots are (supposed to be) ignored?

Regards, NU.
« Last Edit: 09 October 2020, 16:45 by newuzer »
Logged


Roman

  • Global Moderator
  • Member
  • ***
  • Karma: 102
  • Offline Offline
  • Posts: 3064
  • Operating System:
  • Windows NT 10.0 Windows NT 10.0
  • Browser:
  • Chrome 86.0.4240.75 Chrome 86.0.4240.75
    • View Profile
Re: Filename trailing dots cut-off
« Reply #1 on: 09 October 2020, 18:22 »

I will have a look ;)
Logged

newuzer

  • Member
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 20
  • Operating System:
  • Windows NT 10.0 Windows NT 10.0
  • Browser:
  • Firefox 81.0 Firefox 81.0
    • View Profile
Re: Filename trailing dots cut-off
« Reply #2 on: 09 October 2020, 19:13 »

MAMEdev responded with a fix for the named set.
https://github.com/mamedev/mame/commit/3d7aef469cb6b0e6db423b11bbd3bd22e7d35e8e
They will also add checks to -validate to go through the labels and check for CHDs with extensions or otherwise.

It's still interesting to investigate whether it's correct behavior or not.
I think clrmamepro acts by MAME design/convention, that extension separators (.) should not be part of the (file) label.

NU.
« Last Edit: 09 October 2020, 19:31 by newuzer »
Logged

ArconEmu

  • Member
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 31
  • Operating System:
  • Windows NT 10.0 Windows NT 10.0
  • Browser:
  • Chrome 85.0.4183.121 Chrome 85.0.4183.121
    • View Profile
Re: Filename trailing dots cut-off
« Reply #3 on: 10 October 2020, 00:35 »

I think the correct character in this case would be 'Horizontal Ellipsis' = '…', see: https://www.fileformat.info/info/unicode/char/2026/index.htm
But I'm not sure if that is supported by MAME.

But naturally that depends whether your OS supports it or not.
« Last Edit: 10 October 2020, 00:41 by ArconEmu »
Logged
The social dynamics of the net are a direct consequence of the fact that nobody has yet developed a Remote Strangulation Protocol. (Larry Wall, creator of Perl)

Roman

  • Global Moderator
  • Member
  • ***
  • Karma: 102
  • Offline Offline
  • Posts: 3064
  • Operating System:
  • Windows NT 10.0 Windows NT 10.0
  • Browser:
  • Chrome 86.0.4240.75 Chrome 86.0.4240.75
    • View Profile
Re: Filename trailing dots cut-off
« Reply #4 on: 10 October 2020, 08:45 »

I found the part in the source code already which is responsible for trimming the dots at the end.
Assume it gets fixed for the next version.


I remember why I added it. Actually you cannot create a folder under windows with a "." at the end. You can successfully run a mkdir test. from commandline and you can even make a dir test. but it will appear without the dot and a dir test will do the same.
But you can create files with dots at the end...so I will remove the trimming.
« Last Edit: 10 October 2020, 12:23 by Roman »
Logged

Roman

  • Global Moderator
  • Member
  • ***
  • Karma: 102
  • Offline Offline
  • Posts: 3064
  • Operating System:
  • Windows NT 10.0 Windows NT 10.0
  • Browser:
  • Chrome 86.0.4240.75 Chrome 86.0.4240.75
    • View Profile
Logged

newuzer

  • Member
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 20
  • Operating System:
  • Windows NT 10.0 Windows NT 10.0
  • Browser:
  • Firefox 81.0 Firefox 81.0
    • View Profile
Re: Filename trailing dots cut-off
« Reply #6 on: 11 October 2020, 19:58 »

Thanks Roman, but...
The requested URL /clrmamepro/binaries/cmpro20201010.7z was not found on this server.
« Last Edit: 11 October 2020, 20:01 by newuzer »
Logged

Roman

  • Global Moderator
  • Member
  • ***
  • Karma: 102
  • Offline Offline
  • Posts: 3064
  • Operating System:
  • Windows NT 10.0 Windows NT 10.0
  • Browser:
  • Chrome 86.0.4240.75 Chrome 86.0.4240.75
    • View Profile
Re: Filename trailing dots cut-off
« Reply #7 on: 11 October 2020, 20:01 »

because I've just updated the link to today ;)
Logged
Pages: [1]   Go Up
 

Page created in 0.13 seconds with 21 queries.