Bug - Resources with case-conflicts

ApocDevApocDev Posts: 14
edited March 11, 2011 9:35AM in SmartAssembly
When obfuscating assemblies with resources using different casing (eg; zh-Hans and zh-hans) SA will overwrite one of them, causing them to be useless.

We have roughly 20 projects that are merged into the final exe via SA. So it took quite a while to figure out exactly where the bug was. I'm not sure if this is actually a bug with SA, or just that windows doesn't really care about casing at all.

Also; is there some form of bug tracker, or similar where I should be reporting bugs? (Luckily, we've only found 2 bugs to date, this one being the most annoying to figure out)

Comments

  • This really does look like an OS issue.

    Forgive me but I do not understand the significance of case-sensitivity of sattelite resources. Perhaps the obvious question is- how does your system work, without smartassembly? (How do you get the file system to respect case-sensitivity such that no over-writing occurs). Could it be that seperate smartassembly projects are needed?
    You can embed protected assemblies as well as merge- this may be how you can best workaround this.

    >>Also; is there some form of bug tracker, or similar where I should be reporting bugs?

    Not publically available, sorry, no. This forum works and, if necessary, we open a formal support ticket if you write to: support@red-gate.com
  • When our projects are not obfuscated, there is no issue, as Windows ignores the folder casing all together.

    E.g; say you have 2 projects (Project1, and Project2)

    Project1 uses zh-hans/Project1.resources.dll
    Project2 uses zh-Hans/Project2.resources.dll

    This is fine, as windows will create the folder for whichever is encountered first, and just place both DLLs in the same folder. (For the sake of argument, lets say it uses zh-hans)

    This gives you;
    zh-hans/Project1.resources.dll
    zh-hans/Project2.resources.dll

    However, when SA merges assemblies, it reads them as 2 "distinct" cultures (which they technically, are not), and will generate resources for zh-hans, then generate resources for zh-Hans, which overwrites "Project1"'s resources.

    zh-hans/MergedProject.resources.dll
    zh-Hans/MergedProject.resources.dll

    Hopefully that shows where the issue is.

    I hope that's more clear.
  • OK, thank you. Please do not merge or embed the satellite assemblies as it's known that this breaks their loading. Sorry.
Sign In or Register to comment.