diff options
author | Peter Stephenson <pws@users.sourceforge.net> | 2003-07-04 16:27:36 +0000 |
---|---|---|
committer | Peter Stephenson <pws@users.sourceforge.net> | 2003-07-04 16:27:36 +0000 |
commit | 554605ee04946160e360354c4aee9102c877ac19 (patch) | |
tree | 0488e3d86aefe4a93707e44a5b267a5379cb4393 /Functions/TCP/tcp_expect | |
parent | e50b688cd5d246a6134fe614ae4efdf9e7dd649e (diff) | |
download | zsh-554605ee04946160e360354c4aee9102c877ac19.tar.gz zsh-554605ee04946160e360354c4aee9102c877ac19.tar.xz zsh-554605ee04946160e360354c4aee9102c877ac19.zip |
18810: Various enhancements and bug fixes for the TCP function suite
Diffstat (limited to 'Functions/TCP/tcp_expect')
-rw-r--r-- | Functions/TCP/tcp_expect | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/Functions/TCP/tcp_expect b/Functions/TCP/tcp_expect index 14963a3e6..e49f93804 100644 --- a/Functions/TCP/tcp_expect +++ b/Functions/TCP/tcp_expect @@ -37,8 +37,12 @@ emulate -L zsh setopt extendedglob -# Get extra accuracy by making SECONDS floating point locally -typeset -F SECONDS +if [[ ${(t)SECONDS} != float* ]]; then + # If called from another function, use that + typeset -F TCP_SECONDS_START=$SECONDS + # Get extra accuracy by making SECONDS floating point locally + typeset -F SECONDS +fi # Variables are all named _expect_* to avoid problems with the -p param. local _expect_opt _expect_pvar |