Package: libhal-storage0
Version: 0.4.8-2
Severity: important
Tags: patch
hal-spec claims, that:
volume.disc.type (string) Yes This property specifies the physical type of
the disc
...
dvd_plus_r DVD+R disc
dvd_plus_rw DVD+RW disc
...
However, in libhal-storage.c:hal_volume_from_udi() we have
(as of 0.4.8-2):
} else if (strcmp (disc_type_textual, "dvd_plusr") == 0) {
vol->disc_type = HAL_VOLUME_DISC_TYPE_DVDPLUSR;
} else if (strcmp (disc_type_textual, "dvd_plusrw") == 0) {
vol->disc_type = HAL_VOLUME_DISC_TYPE_DVDPLUSRW;
}
As you see, there are two typos (dvd_plusr - should be dvd_plus_r,
and dvd_plusrw - should be dvd_plus_rw), which prevent a disk type
to be set for DVD+R and DVD+RW disks. As a result, KDE 3.4 media
manager misrecognize those disks, claiming they are CD-ROMs.
The attached patch fixes the typos. It should be put in debian/patches.
The patched hal compiles without any problems with pbuilder and KDE 3.4
media manager behaves as expected after installing it. Please include it
in the next hal revision, because the nature of the bug may trick the people
heavily relying on the info provided by Hal/KDE/Gnome into thinking that
their DVD drive is faulty (yes, I had this thought!). I'm not sure
whether the bug is worth fixing in sarge. It's very trivial and just can't
break anything.
-- System Information:
Debian Release: testing/unstable
APT prefers unstable
APT policy: (500, 'unstable')
Architecture: amd64 (x86_64)
Shell: /bin/sh linked to /bin/bash
Kernel: Linux 2.6.12-mdx
Locale: LANG=lt_LT, LC_CTYPE=lt_LT (charmap=ISO-8859-13)
Versions of packages libhal-storage0 depends on:
ii dbus-1 0.23.4-3 simple interprocess messaging syst
ii libc6 2.3.2.ds1-22 GNU C Library: Shared libraries an
ii libhal0 0.4.8-2mdx1 Hardware Abstraction Layer - share
ii libpopt0 1.7-5 lib for parsing cmdline parameters
libhal-storage0 recommends no packages.
-- no debconf information
diff -uNr hal-0.4.8.old/libhal-storage/libhal-storage.c
hal-0.4.8/libhal-storage/libhal-storage.c
--- hal-0.4.8.old/libhal-storage/libhal-storage.c 2005-06-25
18:26:30.000000000 +0300
+++ hal-0.4.8/libhal-storage/libhal-storage.c 2005-06-25 18:27:41.000000000
+0300
@@ -1028,9 +1028,9 @@
vol->disc_type = HAL_VOLUME_DISC_TYPE_DVDR;
} else if (strcmp (disc_type_textual, "dvd_rw") == 0) {
vol->disc_type = HAL_VOLUME_DISC_TYPE_DVDRW;
- } else if (strcmp (disc_type_textual, "dvd_plusr") == 0) {
+ } else if (strcmp (disc_type_textual, "dvd_plus_r") == 0) {
vol->disc_type = HAL_VOLUME_DISC_TYPE_DVDPLUSR;
- } else if (strcmp (disc_type_textual, "dvd_plusrw") == 0) {
+ } else if (strcmp (disc_type_textual, "dvd_plus_rw") == 0) {
vol->disc_type = HAL_VOLUME_DISC_TYPE_DVDPLUSRW;
}
}