]> git.saurik.com Git - apt.git/blobdiff - cmdline/apt-cdrom.cc
CDROMs are unmounted
[apt.git] / cmdline / apt-cdrom.cc
index 102519f59775ee9c8a43cbd19bb7e6e43c9ecb9e..9b826a566721bd3900611c5b30f3f1794662ffed 100644 (file)
@@ -1,6 +1,6 @@
 // -*- mode: cpp; mode: fold -*-
 // Description                                                         /*{{{*/
-// $Id: apt-cdrom.cc,v 1.30 1999/08/12 07:00:55 jgg Exp $
+// $Id: apt-cdrom.cc,v 1.32 1999/09/03 05:46:48 jgg Exp $
 /* ######################################################################
    
    APT CDROM - Tool for handling APT's CDROM database.
@@ -63,7 +63,7 @@ bool FindPackages(string CD,vector<string> &List,vector<string> &SList,
    /* Aha! We found some package files. We assume that everything under 
       this dir is controlled by those package files so we don't look down
       anymore */
-   if (stat("Packages",&Buf) == 0 || stat("Packages.gz",&Buf))
+   if (stat("Packages",&Buf) == 0 || stat("Packages.gz",&Buf) == 0)
    {
       List.push_back(CD);
       
@@ -91,6 +91,7 @@ bool FindPackages(string CD,vector<string> &List,vector<string> &SList,
       if (strcmp(Dir->d_name,".") == 0 ||
          strcmp(Dir->d_name,"..") == 0 ||
          //strcmp(Dir->d_name,"source") == 0 ||
+         strcmp(Dir->d_name,".disk") == 0 ||
          strcmp(Dir->d_name,"experimental") == 0 ||
          strcmp(Dir->d_name,"binary-all") == 0)
         continue;
@@ -537,11 +538,12 @@ bool DoAdd(CommandLine &)
 
    if (_config->FindB("Debug::aptcdrom",false) == true)
    {
-      cout << "I found:" << endl;
+      cout << "I found (binary):" << endl;
       for (vector<string>::iterator I = List.begin(); I != List.end(); I++)
-      {
         cout << *I << endl;
-      }      
+      cout << "I found (source):" << endl;
+      for (vector<string>::iterator I = sList.begin(); I != sList.end(); I++)
+        cout << *I << endl;
    }   
    
    // Fix up the list