patch-2.2.0-pre5 linux/drivers/cdrom/cdrom.c

Next file: linux/drivers/char/cyclades.c
Previous file: linux/drivers/block/rz1000.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.2.0-pre4/linux/drivers/cdrom/cdrom.c linux/drivers/cdrom/cdrom.c
@@ -376,8 +376,10 @@
 			}
 			cdinfo(CD_OPEN, "the tray is now closed.\n"); 
 		}
-		if (ret!=CDS_DISC_OK)
+		if (ret!=CDS_DISC_OK) {
+			ret = -ENOMEDIUM;
 			goto clean_up_and_return;
+		}
 	}
 	cdrom_count_tracks(cdi, &tracks);
 	if (tracks.error == CDS_NO_DISC) {

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov