summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Vogt <michael.vogt@ubuntu.com>2011-07-25 16:53:18 +0200
committerMichael Vogt <michael.vogt@ubuntu.com>2011-07-25 16:53:18 +0200
commitf748b4760d0f8247001c0b46e9eaf02b379bc3c4 (patch)
treedd5c42aff17e47fda83f6d3faa7c6de7c9719a7c
parentfd8b88d6ece1382cf3441efe721ec84d43a19bbe (diff)
* apt-pkg/contrib/cdromutl.cc:
- fix escape problem when looking for the mounted devices
-rw-r--r--apt-pkg/contrib/cdromutl.cc8
-rw-r--r--debian/changelog2
2 files changed, 9 insertions, 1 deletions
diff --git a/apt-pkg/contrib/cdromutl.cc b/apt-pkg/contrib/cdromutl.cc
index 821e6d688..551efa7d9 100644
--- a/apt-pkg/contrib/cdromutl.cc
+++ b/apt-pkg/contrib/cdromutl.cc
@@ -258,7 +258,13 @@ string FindMountPointForDevice(const char *devnode)
if(TokSplitString(' ', buf, out, 10))
{
fclose(f);
- return string(out[1]);
+ // unescape \040 and return the path
+ size_t pos;
+ string mount_point = out[1];
+ static const char *needle = "\\040";
+ while ((pos = mount_point.find(needle)) != string::npos)
+ mount_point.replace(pos, strlen(needle), " ");
+ return mount_point;
}
}
}
diff --git a/debian/changelog b/debian/changelog
index 418f37f4d..29a571fb9 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -4,6 +4,8 @@ apt (0.8.15.2) unstable; urgency=high
code (LP: #784473)
* cmdline/apt-get.cc:
- fix missing download progress in apt-get download
+ * apt-pkg/contrib/cdromutl.cc:
+ - fix escape problem when looking for the mounted devices
-- Michael Vogt <mvo@debian.org> Tue, 12 Jul 2011 11:54:47 +0200