Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 17 Jun 2009 21:58:32 +0000 (UTC)
From:      Jilles Tjoelker <jilles@FreeBSD.org>
To:        cvs-src-old@freebsd.org
Subject:   cvs commit: src/bin/sh input.c
Message-ID:  <200906172158.n5HLwrbn018272@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
jilles      2009-06-17 21:58:32 UTC

  FreeBSD src repository

  Modified files:
    bin/sh               input.c 
  Log:
  SVN rev 194406 on 2009-06-17 21:58:32Z by jilles
  
  Properly flush input after an error in backquotes in interactive mode.
  
  For parsing an old-style backquote substitution (`...`),
  a string "file" is used to store the contents of the
  substitution (with the special backslash processing done).
  If an error occurs, the shell cleans up all these files
  (returning to the top level) and flush the top level
  file. Erroneously, it first flushed the current file and
  then cleaned up all extra files, so that the top level
  file (i.e. the terminal) was not flushed.
  
  Example (in interactive mode):
    echo `for` echo This should not be printed
  
  Also noticeable in (in interactive mode):
    echo `(`
  The old version prints an extraneous prompt.
  
  Approved by:    ed (mentor)
  
  Revision  Changes    Path
  1.25      +1 -1      src/bin/sh/input.c



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200906172158.n5HLwrbn018272>