Bug#541493: live-initramfs: Bug in where_is_mounted()
On January 22, 2010, Daniel Baumann <email@example.com> wrote:
> tag 541493 moreinfo
I've been playing around with different ways to boot a live-cd ISO
images to provide a solution for pseudo anonymous / obfuscated OS
sessions. With relatively few boot-time modifications, I was able to
boot a live-cd ISO stored on a hard drive loaded with Debian using grub.
Basically, the user can choose, at the grub boot menu, whether to run
their regular operating system or a live-cd iso from the mounted hard
drive. This means that they can boot an live-cd OS and leave no
permanent trace of anything done in that booted session, without having
to carry around an actual live cd.
Unfortunately, the way the where_is_mounted() function is currently
written assumes that there is only one mounted device that matches the
query. In my particular case there are more and the function returns
them all. Since the code calling the function does not expect to get
back multiple lines, it fails during boot.
I assumed that the comment in the function meant that the author
intended to only return the first match found. Changing the code as I
recommended ensures that is what happens.
I can provide more info, logs, etc. if you need to understand this case
better. Regardless, the code change has no ill effect that I can see and
will behave exactly the way it currently does for 99.9% of the people