From 9e0349cc4674d0f90434e415e157a21f1ff9589b Mon Sep 17 00:00:00 2001 From: Arch Librarian Date: Mon, 20 Sep 2004 16:52:19 +0000 Subject: Fixes Author: jgg Date: 1998-12-22 07:52:05 GMT Fixes --- methods/cdrom.cc | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'methods/cdrom.cc') diff --git a/methods/cdrom.cc b/methods/cdrom.cc index 0187283c1..35a9b044d 100644 --- a/methods/cdrom.cc +++ b/methods/cdrom.cc @@ -1,6 +1,6 @@ // -*- mode: cpp; mode: fold -*- // Description /*{{{*/ -// $Id: cdrom.cc,v 1.5 1998/12/22 07:41:25 jgg Exp $ +// $Id: cdrom.cc,v 1.6 1998/12/22 07:52:05 jgg Exp $ /* ###################################################################### CDROM URI method for APT @@ -56,7 +56,6 @@ string CDROMMethod::GetID(string Name) { _error->Error("Unable to read the cdrom database %s", DFile.c_str()); - Fail(); return string(); } } @@ -95,20 +94,22 @@ bool CDROMMethod::Fetch(FetchItem *Itm) } string ID = GetID(Get.Host); + if (_error->PendingError() == true) + return false; // All non IMS queries for package files fail. if (Itm->IndexFile == true || ID.empty() == true) { Fail("Please use apt-cdrom to make this CD recognized by APT." " apt-get update cannot be used to add new CDs"); - return false; + return true; } // We already have a CD inserted, but it is the wrong one if (CurrentID.empty() == false && ID != CurrentID) { Fail("Wrong CD",true); - return false; + return true; } string CDROM = _config->FindDir("Acquire::cdrom::mount","/cdrom/"); @@ -129,7 +130,7 @@ bool CDROMMethod::Fetch(FetchItem *Itm) { CurrentID = "FAIL"; Fail("Wrong CD",true); - return false; + return true; } MountCdrom(CDROM); -- cgit v1.2.3