]> git.saurik.com Git - apt.git/blobdiff - methods/cdrom.cc
add new "Acquire::cdrom::AutoDetect" config that enables/disables
[apt.git] / methods / cdrom.cc
index b0f1a1551b0c179294ed2a492ca9f09fb7340162..b3f4618165ae8c3c4cf3f5b1c68481d9c2f812ab 100644 (file)
@@ -218,6 +218,7 @@ bool CDROMMethod::Fetch(FetchItem *Itm)
       return true;
    }
 
+   bool AutoDetect = _config->FindB("Acquire::cdrom::AutoDetect", false);
    CDROM = _config->FindDir("Acquire::cdrom::mount","/cdrom/");
    if (Debug)
       clog << "Looking for CDROM at " << CDROM << endl;
@@ -228,7 +229,7 @@ bool CDROMMethod::Fetch(FetchItem *Itm)
    string NewID;
    while (CurrentID.empty() == true)
    {
-      if (CDROM == "apt-udev-auto/") 
+      if (AutoDetect)
         AutoDetectAndMount(Get, NewID);
 
       if(!IsMounted(CDROM))