Summary: | xdg-desktop-menu improperly check for vendor prefix on Estonian locale | ||
---|---|---|---|
Product: | Portland | Reporter: | marmarek |
Component: | xdg-utils | Assignee: | Portland Bugs <portland-bugs> |
Status: | RESOLVED FIXED | QA Contact: | |
Severity: | normal | ||
Priority: | medium | ||
Version: | 1.1.0 | ||
Hardware: | All | ||
OS: | Linux (All) | ||
Whiteboard: | |||
i915 platform: | i915 features: |
Description
marmarek
2013-10-21 22:35:12 UTC
Thanks for the excellent report and diagnosis. In a perfect world [[:alpha:]] would be the way to go, but for compatibility's sake, LC_COLLATE=C may be safer and more portable. I'll try to review the whole code base this coming week, to ensure there are no other gotcha's like this one. The code in question: check_vendor_prefix() { file_label="$2" [ -n "$file_label" ] || file_label="filename" file=`basename "$1"` case "$file" in [a-zA-Z]*-*) return ;; esac Considering this code, (re)setting LC_ vars doesn't seem viable without rewriting. Replacing [a-zA-Z]*-*) with [[:alpha:]]*-*) seems to work. Re-reading http://standards.freedesktop.org/menu-spec/menu-spec-latest.html#merge-algorithm where it mentions vendor prefix, I see no mention of locale either. :( is the [[:alpha:]] construct posix? do all shells support it? what shells you tested with? Yes (according to bash man page at least), I don't know, bash, respectively |
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.