modloader icon indicating copy to clipboard operation
modloader copied to clipboard

Mods stop working when folder names have unusual letters

Open thelink2012 opened this issue 8 years ago • 3 comments

This is a weird issue that's been reported since the 0.1.x releases, I can't find the logic behind it, heavy testing needs to be made to identify the issue. It seems pretty random too.

For example:

With this Lincoln Continental from MadDriver I even had problems with the folder name that seens to be using unusuall letters. Even when putting the blank folder "Lincoln Continental Sedan (53А) 1962" without any content in the modloader directory it randomly disables other mods. Very strange and took me some time to figure it out.

thelink2012 avatar Jul 12 '15 16:07 thelink2012

This happens because Loader::ModInformation::Scan has a ::scoped_gdir that does not signal failure. Since we don't use WinAPI Wide API, when we go after a non-ASCII directory it'll fail and will essentially read the modloader/ directory.

Either:

  • Make proper unique support.
  • Or throw an exception (and of course catch it at the correct place) when scoped_gdir and such fails.
  • Or both!

thelink2012 avatar Jul 13 '15 04:07 thelink2012

Unicode support, now! :p

quiret avatar Jul 13 '15 08:07 quiret

My two cents: https://pastebin.com/aYaBhtR5 Caused by U+200E character. Look at the "ai upscaled weapon textures + icons" folder name.

JuniorDjjr avatar Mar 24 '19 08:03 JuniorDjjr