summaryrefslogtreecommitdiff
path: root/extras/cdrom_id
diff options
context:
space:
mode:
authorMartin Pitt <martin.pitt@ubuntu.com>2010-08-30 15:33:26 +0200
committerMartin Pitt <martin.pitt@ubuntu.com>2010-08-30 15:33:26 +0200
commit2458db3edd8d66827b34978ff471dff8f879e9ab (patch)
tree50a32b03ab1e049e480b70676dba866660c2fc9a /extras/cdrom_id
parentd17c065e28fa4baac90b02b4913c7ef32d54f3c7 (diff)
cdrom_id: Fix DVD-RW media detection
Commit cf2205a19 applied the "restricted overwrite" vs. "sequential" DVD-RW test to feature_profiles() (which reads the drive capabilities), which caused every DVD medium to be detected as ID_CDROM_MEDIA_DVD_RW. Now apply it to cd_profiles() instead, to just check the current profile.
Diffstat (limited to 'extras/cdrom_id')
-rw-r--r--extras/cdrom_id/cdrom_id.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/extras/cdrom_id/cdrom_id.c b/extras/cdrom_id/cdrom_id.c
index f9d6e0bc24..8480d7b334 100644
--- a/extras/cdrom_id/cdrom_id.c
+++ b/extras/cdrom_id/cdrom_id.c
@@ -297,14 +297,9 @@ static int feature_profiles(struct udev *udev, const unsigned char *profiles, si
cd_dvd_ram = 1;
break;
case 0x13:
- info(udev, "profile 0x%02x media_dvd_rw\n", profile);
- cd_media_dvd_rw = 1;
- cd_media_dvd_rw_ro = 1;
- break;
case 0x14:
info(udev, "profile 0x%02x dvd_rw\n", profile);
cd_dvd_rw = 1;
- cd_media_dvd_rw_seq = 1;
break;
case 0x1B:
info(udev, "profile 0x%02x dvd_plus_r\n", profile);
@@ -486,10 +481,16 @@ static int cd_profiles(struct udev *udev, int fd)
cd_media_dvd_ram = 1;
break;
case 0x13:
+ info(udev, "profile 0x%02x media_dvd_rw_ro\n", cur_profile);
+ cd_media = 1;
+ cd_media_dvd_rw = 1;
+ cd_media_dvd_rw_ro = 1;
+ break;
case 0x14:
- info(udev, "profile 0x%02x media_dvd_rw\n", cur_profile);
+ info(udev, "profile 0x%02x media_dvd_rw_seq\n", cur_profile);
cd_media = 1;
cd_media_dvd_rw = 1;
+ cd_media_dvd_rw_seq = 1;
break;
case 0x1B:
info(udev, "profile 0x%02x media_dvd_plus_r\n", cur_profile);