On Fri, Feb 11, 2011 at 4:28 PM, Alessio Sangalli <[email protected]> wrote: > Hi, I am using the owshell family of commands, usually from scripts; I > usually capture the output of the command into a variable: > > sometimes for whatever reason - owread fails, maybe because owserver is > not up (yet) or similar. > > How do I detect the "error" condition? The man page of "owshell" does > not mention any exit code "strategy". I had a look at the source so it > seems the exit code is 0 if successful and 1 if error - but is there an > "official" behaviour? >
You are right. There is no RETURN VALUE section of the man pages. What would you suggest? 0 for good, obviously, and 1 for error? All errors wouldn't be captured, like a bad 85C reading (although are automatically repeated). But connection and memory allocation and bad command line parameters would be easy to report. Paul Alfille ------------------------------------------------------------------------------ The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE: Pinpoint memory and threading errors before they happen. Find and fix more than 250 security defects in the development cycle. Locate bottlenecks in serial and parallel code that limit performance. http://p.sf.net/sfu/intel-dev2devfeb _______________________________________________ Owfs-developers mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/owfs-developers
