--- hal-0.5.8_git20061106/hald/linux/probing/probe-volume.c 2006-10-27 18:22:20.000000000 +0200 +++ hal-0.5.8_git20061106_save/hald/linux/probing/probe-volume.c 2006-11-27 17:38:27.000000000 +0100 @@ -380,7 +380,7 @@ if (is_disc) { int type; guint64 capacity; - struct cdrom_tochdr toc_hdr; + struct cdrom_tochdr; /* toc_hdr; */ /* defaults */ libhal_changeset_set_property_string (cs, "volume.disc.type", "unknown"); @@ -519,22 +519,11 @@ libhal_changeset_set_property_bool (cs, "volume.disc.is_appendable", TRUE); } - /* In November 2005, Kay wrote: - * - * "This seems to cause problems on some drives with broken firmware, - * comment it out until we really need multisession support." - * - * However, we really need this for - * - * - supporting mixed CD's - we want to probe the data track which - * may not be the first track; normally it's the last one... - * - getting the right label for multi-session discs (fd.o bug #2860) - * - * So if there are still drives around with broken firmware we need - * to blacklist them. - */ +#if 0 + /* This seems to cause problems on some drives with broken firmware, + * comment it out until we really need multisession support */ - /* check if last track is a data track */ + /* check for multisession disks */ if (ioctl (fd, CDROMREADTOCHDR, &toc_hdr) == 0) { struct cdrom_tocentry toc_entr; unsigned int vol_session_count = 0; @@ -553,18 +542,16 @@ } } } - +#endif /* try again, to get last session that way */ if (vol_probe_offset == 0) { struct cdrom_multisession ms_info; memset(&ms_info, 0x00, sizeof(ms_info)); ms_info.addr_format = CDROM_LBA; - if (ioctl(fd, CDROMMULTISESSION, &ms_info) == 0) { - if (!ms_info.xa_flag) { + if (ioctl(fd, CDROMMULTISESSION, &ms_info) == 0) + if (!ms_info.xa_flag) vol_probe_offset = ms_info.addr.lba * block_size; - } - } } }