![]() |
|
|
|
|
|||||||
| Forums | Portal | Register | Forum Rules | FAQ | Contribute | Members List | Arcade | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts here. |
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Calling expect scripts from other expect scripts | seva | Shell Programming and Scripting | 0 | 04-03-2008 10:45 AM |
| Tcl expect HELP | dave_m | Shell Programming and Scripting | 0 | 02-27-2008 07:08 AM |
| Expect/Tcl help? | earnstaf | UNIX for Dummies Questions & Answers | 2 | 07-26-2007 07:01 AM |
| Expect and auto expect command | arun_v | Shell Programming and Scripting | 0 | 03-29-2006 04:31 AM |
| Expect with tcl/tk | sanjustudy | Shell Programming and Scripting | 0 | 10-10-2005 02:48 AM |
|
|
Submit Tools | LinkBack | Thread Tools | Display Modes |
|
|||
|
Can someone identify what is the problem here?.
no children while executing "exp_wait -nowait -i -1" (procedure "logOptions" line 45) invoked from within "logOptions" (procedure "doExecute" line 98) invoked from within "doExecute" (procedure "main" line 32) invoked from within "main $argc $argv" |
| Forum Sponsor | ||
|
|
|
|||
|
Little background:
This is a expect-tk script which we have it on a Sun-sparc WS. The script was working fine before we upgraded the machine from solaris 9.0 to solaris 10.0. Now the script does not execute properly, as seen in the error message it does not identify the child process and above procedures fail Code:
(procedure "logOptions" line 45)
invoked from within
(procedure "doExecute" line 98)
(procedure "main" line 32)
"main $argc $argv"
If you need any other information please let me know. Last edited by Yogesh Sawant; 04-18-2008 at 01:14 AM. Reason: added code tags |
|
|||
|
Tcl version btwn 9 & 10? Are you using an expect binary or loading as a package?
The error message is pretty benevolent in theory. It's the same call as: Code:
waitpid(-1,&status,WNOHANG); message you will get. There is also the possibilty that you are simply calling exec instead of fork and exec in which case behavior is random after the first wait iirc. Have you considered asynchronously handling SIGCHLD via trap as an experiment? |
|
|||
|
Tcl version btwn 9 & 10? -- No the solaris version 9 and 10.
Are you using an expect binary or loading as a package? -- it is a binary. (expect1.1) Have you considered asynchronously handling SIGCHLD via trap as an experiment? -- how do I do that?. |
|
|||
|
Yes, sorry. I meant what are the expect revisions between sol9 and sol10? Are they identical? More importantly are the tcl/tk installations of the same version between
solaris 9 and 10? If using a mismatched expect binary with different versions of tcl/tk installed behaviors like this are common. OTOH, it could be a bug in the newer version of expect. As for how to async handle signals you just install a handler. Code:
proc waitonchld {} {
set ret [exp_wait -nowait -i -1]
puts "Handled child exit $ret"
}
trap -code waitonchld {SIGCHLD}
|