I created the following expect script in order to automate logging into a VPN:
#!/usr/bin/expect
set PASS [lindex $argv 0]
set timeout 10
spawn vpnc
expect : {send $PASS\r}
expect eof
However, when I give wrong password argument, the expected 10 second does not occur.
Why does this 10 second timeout not occur?