- bool IsCorrectCD(URI want, string MountPath);
- bool AutoDetectAndMount(URI);
+ bool IsCorrectCD(URI want, string MountPath, string& NewID);
+ bool AutoDetectAndMount(const URI, string &NewID);
// CDROMMethod::AutoDetectAndMount /*{{{*/
// ---------------------------------------------------------------------
/* Modifies class varaiable CDROM to the mountpoint */
// CDROMMethod::AutoDetectAndMount /*{{{*/
// ---------------------------------------------------------------------
/* Modifies class varaiable CDROM to the mountpoint */
- if (!FileExists("/media/apt"))
- mkdir("/media/apt", 0755);
+ string AptMountPoint = _config->FindDir("Dir::Media::MountPath");
+ if (!FileExists(AptMountPoint))
+ mkdir(AptMountPoint.c_str(), 0750);
// CDROMMethod::IsCorrectCD /*{{{*/
// ---------------------------------------------------------------------
/* */
// CDROMMethod::IsCorrectCD /*{{{*/
// ---------------------------------------------------------------------
/* */
for (unsigned int Version = 2; Version != 0; Version--)
{
if (IdentCdrom(MountPath,NewID,Version) == false)
for (unsigned int Version = 2; Version != 0; Version--)
{
if (IdentCdrom(MountPath,NewID,Version) == false)
CDROM = _config->FindDir("Acquire::cdrom::mount","/cdrom/");
if (Debug)
clog << "Looking for CDROM at " << CDROM << endl;
if (CDROM[0] == '.')
CDROM= SafeGetCWD() + '/' + CDROM;
CDROM = _config->FindDir("Acquire::cdrom::mount","/cdrom/");
if (Debug)
clog << "Looking for CDROM at " << CDROM << endl;
if (CDROM[0] == '.')
CDROM= SafeGetCWD() + '/' + CDROM;