From: Adrian P. <a.p...@dn...> - 2000-11-15 11:50:59
|
Goood day, First a thanks to all those who have had a hand in Expect. I've just started using Expect for interaction with passwd and I noticed if $object->expect times out then exp_before is not set as documented in the manual. A patch against 1.08 follows which seems to fix this. Sincerely, Adrian Phillips -- Your mouse has moved. Windows NT must be restarted for the change to take effect. Reboot now? [OK] *** Expect.pm~ Wed Sep 20 11:56:41 2000 --- Expect.pm Wed Nov 15 12:38:06 2000 *************** *** 733,738 **** --- 733,739 ---- $err = "1:TIMEOUT"; foreach my $pat (@_) { foreach my $exp (@{$pat->[0]}) { + ${*$exp}{exp_Before} = $exp->clear_accum(); next if not defined $exp->fileno(); # skip already closed ${*$exp}{exp_Error} = $err unless ${*$exp}{exp_Error}; } |