Package: bash
Version: 3.1-2
Severity: normal
Tags: patch

When in 'vi' mode, the 'v' command (which normally pops you into vi with
the current command line) breaks, with a syntax error.

The problem is a typo in the patch for the VI_EDIT_COMMAND fc... an
extra ')'

The attached patch is to the diff file (the only place I can find the
bug).

To reproduce:

        set -x
        set -o vi 
        [esc]v

produces:

        +++ command -v editor
        ++ fc -e '/usr/bin/editor)'
        bash: syntax error near unexpected token `)'

-- System Information:
Debian Release: testing/unstable
  APT prefers testing
  APT policy: (990, 'testing'), (500, 'unstable'), (500, 'stable'), (1, 
'experimental')
Architecture: i386 (i686)
Shell:  /bin/sh linked to /UNIONFS/bin/bash
Kernel: Linux 2.6.15
Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968) (ignored: LC_ALL set to C)

Versions of packages bash depends on:
ii  base-files                    3.1.10     Debian base system miscellaneous f
ii  debianutils                   2.15.2     Miscellaneous utilities specific t
ii  libc6                         2.3.5-13   GNU C Library: Shared libraries an
ii  libncurses5                   5.5-1      Shared libraries for terminal hand

bash recommends no packages.

-- no debconf information
--- -   2006-04-07 08:09:49.346183000 -0700
+++ bash_3.1-2.diff     2006-04-07 08:06:36.000000000 -0700
@@ -1449,7 +1449,7 @@
 + 
 +-#define VI_EDIT_COMMAND              "fc -e \"${VISUAL:-${EDITOR:-vi}}\""
 +-#define EMACS_EDIT_COMMAND   "fc -e \"${VISUAL:-${EDITOR:-emacs}}\""
-++#define VI_EDIT_COMMAND              "fc -e \"${VISUAL:-${EDITOR:-$(command 
-v editor || echo vi))}}\""
+++#define VI_EDIT_COMMAND              "fc -e \"${VISUAL:-${EDITOR:-$(command 
-v editor || echo vi)}}\""
 ++#define EMACS_EDIT_COMMAND   "fc -e \"${VISUAL:-${EDITOR:-$(command -v 
editor || echo emacs)}}\""
 + #define POSIX_VI_EDIT_COMMAND        "fc -e vi"
 + 

Reply via email to