--- drip-0.8.1/src/main.c Mon May 27 21:36:47 2002 +++ drip-0.8.1.azarah/src/main.c Mon May 27 21:39:54 2002 @@ -231,10 +231,14 @@ device = g_string_new(""); /* Look for a device in mtab */ - device = drip_system("grep dvd /etc/fstab | awk '{print $1}'",&result,FALSE,TRUE); + device = drip_system("/usr/bin/dripgetdvd.sh dvd",&result,FALSE,TRUE); if (device->len==0 || strstr(device->str,"{empty output}")!=NULL) { - /* Couldn't find anything. Safe default */ - g_string_sprintf(device,"%s","/dev/cdrom"); + /* Couldn't find anything related to dvd, trying cdrom */ + device = drip_system("/usr/bin/dripgetdvd.sh cdrom",&result,FALSE,TRUE); + if (device->len==0 || strstr(device->str,"{empty output}")!=NULL) { + /* Nothing we can do to stop failure, set default */ + g_string_sprintf(device,"%s","/dev/cdrom"); + } } return device->str; } @@ -591,7 +595,7 @@ if (config_ok == FALSE) { /* Default divx related settings */ g_log(DRIP_LD,G_LOG_LEVEL_INFO,"Setting up default configuration..."); - g_string_sprintf(Config.DVDdevice,"%s","/dev/cdrom"); + g_string_sprintf(Config.DVDdevice,"%s",detect_dvdrom()); /* Traceback if Config.DVDdevice is a symbolic link */ DVDsymlink();