Bug 30274 - Underscores in errors are incorrectly squashed
Summary: Underscores in errors are incorrectly squashed
Status: RESOLVED FIXED
Alias: None
Product: dbus
Classification: Unclassified
Component: GLib (show other bugs)
Version: unspecified
Hardware: Other All
: medium major
Assignee: Simon McVittie
QA Contact: John (J5) Palmieri
URL: http://git.collabora.co.uk/?p=user/sm...
Whiteboard:
Keywords: patch
Depends on:
Blocks:
 
Reported: 2010-09-20 02:38 UTC by Christian Dywan
Modified: 2011-01-10 05:03 UTC (History)
3 users (show)

See Also:
i915 platform:
i915 features:


Attachments
Untested patch to leave underscores (1.86 KB, patch)
2010-09-20 02:59 UTC, Christian Dywan
Details | Splinter Review
Add a regression test for errors containing underscores (3.42 KB, patch)
2011-01-04 08:39 UTC, Simon McVittie
Details | Splinter Review

Description Christian Dywan 2010-09-20 02:38:20 UTC
The commit 9637ed9f0c66982a06048b18ccf983881643e456 introduced squashing of ‚-‘, and implicitly ‚_‘ since uscore_to_wincaps treats both the same way. This breaks existing error naming in Maemo. According to the spec, an underscore is a valid character, unlike the hyphen.

I suggest uscore_to_wincaps should ignore underscores in this case, via an additional argument.
Comment 1 Christian Dywan 2010-09-20 02:59:41 UTC
Created attachment 38809 [details] [review]
Untested patch to leave underscores

This change should resolve this. I still need to test it.
Comment 2 Christian Dywan 2010-11-24 02:04:19 UTC
Patch was tested for a while now, it would be nice to see it reviewed.
Comment 3 Simon McVittie 2011-01-04 08:38:43 UTC
I've pushed the patch to master, thanks.

I'd have preferred it to come with a regression test; I've now written one, which I'll attach in a moment (or see my gitweb). Please review.
Comment 4 Simon McVittie 2011-01-04 08:39:44 UTC
Created attachment 41631 [details] [review]
Add a regression test for errors containing underscores
Comment 5 Will Thompson 2011-01-10 04:45:50 UTC
Review of attachment 41631 [details] [review]:

Ship it.
Comment 6 Simon McVittie 2011-01-10 05:03:22 UTC
Shipped it. Commit ID 04e11da4, for 0.94.


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.