diff options
Diffstat (limited to 'apt-pkg/cdrom.cc')
-rw-r--r-- | apt-pkg/cdrom.cc | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/apt-pkg/cdrom.cc b/apt-pkg/cdrom.cc index 72d8e4d41..96d4e9c91 100644 --- a/apt-pkg/cdrom.cc +++ b/apt-pkg/cdrom.cc @@ -829,8 +829,6 @@ bool pkgCdrom::Add(pkgCdromStatus *log) /*{{{*/ } } - - // Unmount and finish if (_config->FindB("APT::CDROM::NoMount",false) == false) { log->Update(_("Unmounting CD-ROM...\n"), STEP_LAST); @@ -921,6 +919,7 @@ pkgUdevCdromDevices::Scan() /*{{{*/ pkgUdevCdromDevices::~pkgUdevCdromDevices() /*{{{*/ { - dlclose(libudev_handle); + if (libudev_handle != NULL) + dlclose(libudev_handle); } /*}}}*/ |