diff options
Diffstat (limited to 'bin/flogin.in')
-rw-r--r-- | bin/flogin.in | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/bin/flogin.in b/bin/flogin.in index 49f057e..24b8400 100644 --- a/bin/flogin.in +++ b/bin/flogin.in @@ -1,8 +1,8 @@ #! @EXPECT_PATH@ -- ## -## $Id: flogin.in,v 1.39 2005/06/14 20:20:43 heas Exp $ +## $Id: flogin.in,v 1.42 2006/08/10 07:00:30 heas Exp $ ## -## Copyright (C) 1997-2004 by Terrapin Communications, Inc. +## Copyright (C) 1997-2006 by Terrapin Communications, Inc. ## All rights reserved. ## ## This software may be freely copied, modified and redistributed @@ -502,12 +502,14 @@ proc run_commands { prompt command } { } send "exit\r" expect { - "\n" { exp_continue } - -re "^\[^ ]+>" { - send "exit\r" - exp_continue } - timeout { return 0 } - eof { return 0 } + "\n" { exp_continue } + -re "^\[^ ]+>" { send "exit\r" + exp_continue + } + timeout { catch {close}; wait + return 0 + } + eof { return 0 } } set in_proc 0 } |