summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2007-11-12 15:51:15 +0000
committerPascal Rigaux <pixel@mandriva.com>2007-11-12 15:51:15 +0000
commit02f63a47ccadce7eb8ed75b1317164012def63c6 (patch)
tree162f70c51d25905a4ab2a522a85e0ceec30f08e4 /lib
parent3260b03a884734319de1b4a2b9f845d23159b906 (diff)
downloaddrakx-kbd-mouse-x11-02f63a47ccadce7eb8ed75b1317164012def63c6.tar
drakx-kbd-mouse-x11-02f63a47ccadce7eb8ed75b1317164012def63c6.tar.gz
drakx-kbd-mouse-x11-02f63a47ccadce7eb8ed75b1317164012def63c6.tar.bz2
drakx-kbd-mouse-x11-02f63a47ccadce7eb8ed75b1317164012def63c6.tar.xz
drakx-kbd-mouse-x11-02f63a47ccadce7eb8ed75b1317164012def63c6.zip
- fix device /dev/input/by-id/usb-$ID_SERIAL-event-mouse for wacoms
when the ID_SERIAL contains special chars
Diffstat (limited to 'lib')
-rw-r--r--lib/mouse.pm1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/mouse.pm b/lib/mouse.pm
index 8440ddd..1c776ba 100644
--- a/lib/mouse.pm
+++ b/lib/mouse.pm
@@ -249,6 +249,7 @@ sub probe_usb_wacom_devices() {
map {
my $ID_SERIAL = chomp_(run_program::get_stdout('/lib/udev/usb_id', $_->{sysfs_path}));
+ $ID_SERIAL =~ s/[^\w#+\-.:=@_]/_/g; #- udev do a further cleanup, eg: "Wacom_Co.,Ltd._MTE-450" => "Wacom_Co._Ltd._MTE-450". cf ALLOWED_CHARS udev.h
my $sysfs_device = "input/by-id/usb-$ID_SERIAL-event-mouse"; #- from /etc/udev/rules.d/60-persistent-input.rules
if ($::isInstall || -e "/dev/$sysfs_device") {
$sysfs_device;