I can reproduce this bug on Maverick amd64 with bash 4.1-2ubuntu4 and
bash-completion 1:1.2-2ubuntu1.

In addition (I believe this can be considered part of the same bug),
bash-completion works fine with umount without sudo, but when I start a
command "sudo umount /media/New" with the intention that it will tab-
complete to "/media/New Volume", instead it tab-completes to "sudo
umount /media/New\\\ Volume". If I press tab again, it appends an
additional "/", and if I press tab twice more after that, it prints out
a garbled list constructed from the list of mounted volumes:

//                                    New\ Volume
boot/                                 Wingardium/
dev/                                  proc/
ee08e8b3-dffd-45c0-bd04-b74dd72a705b  mountPoint/
pts/                                  binfmt_misc/
sda3                                  sys/
sda5                                  connections/
sdb1                                  debug/
sdc1                                  security/
shm/                                  lock/
.gvfs/                                run/
Alucard/

For comparison, here's the output of "mount":

/dev/sda7 on / type ext4 (rw,errors=remount-ro,commit=0)
proc on /proc type proc (rw,noexec,nosuid,nodev)
none on /sys type sysfs (rw,noexec,nosuid,nodev)
fusectl on /sys/fs/fuse/connections type fusectl (rw)
none on /sys/kernel/debug type debugfs (rw)
none on /sys/kernel/security type securityfs (rw)
none on /dev type devtmpfs (rw,mode=0755)
none on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=0620)
none on /dev/shm type tmpfs (rw,nosuid,nodev)
none on /var/run type tmpfs (rw,nosuid,mode=0755)
none on /var/lock type tmpfs (rw,noexec,nosuid,nodev)
/dev/sda5 on /boot type ext2 (rw)
none on /proc/fs/vmblock/mountPoint type vmblock (rw)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc 
(rw,noexec,nosuid,nodev)
gvfs-fuse-daemon on /home/ek/.gvfs type fuse.gvfs-fuse-daemon 
(rw,nosuid,nodev,user=ek)
/dev/sda3 on /media/Wingardium type fuseblk 
(rw,nosuid,nodev,allow_other,blksize=4096)
/dev/sdb1 on /media/Alucard type fuseblk 
(rw,nosuid,nodev,allow_other,blksize=4096)
/dev/sdc1 on /media/New Volume type vfat (rw)

I don't know where the line with the globally-unique identifier and
"mountPoint" came from. The answer is probably obvious...I didn't try
hard to find it, though I'd be pleased to follow instructions to
investigate that or any other aspect of this bug, if it will help in
fixing it. Running "sudo updatedb" followed by "locate ee08e8b3-dffd-
45c0-bd04-b74dd72a705b" and "locate mountPoint" turned up nothing.

Note that I mounted the volume successfully with the command "sudo mount
/dev/sdc1 /media/New\ Volume", and that was correctly produced by tab-
completion starting with "sudo mount /dev/sdc1 /media/New". So bash-
completion seems to work OK with "sudo mount" (at least in this
instance), but not so well with "sudo umount". Erratic indeed.

** Tags added: karmic maverick

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/470037

Title:
  sudo tab autocomplete shows erratic behavior with spaces in names

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to