From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fc89c,c9b1dae3c708de6c,start X-Google-Attributes: gidfc89c,public X-Google-Thread: 1012a6,c9b1dae3c708de6c,start X-Google-Attributes: gid1012a6,public X-Google-Thread: fee84,c9b1dae3c708de6c,start X-Google-Attributes: gidfee84,public X-Google-Thread: f678f,c9b1dae3c708de6c,start X-Google-Attributes: gidf678f,public From: "Brian J. Krupski" Subject: Having problems passing an exit() status to bourne shell Date: 1997/01/31 Message-ID: <32F25E2B.400C@idx.com>#1/1 X-Deja-AN: 213536633 content-type: text/plain; charset=us-ascii organization: IDX Systems Corporation mime-version: 1.0 reply-to: krupski@idx.com newsgroups: comp.unix.programmer,comp.unix.osf.misc,comp.unix.osf.osf1,comp.unix.shell x-mailer: Mozilla 3.0Gold (Win95; I) I am launching a C program from a bourne shell script and trying to exit the C program with an exit() status so that the bourne script can interpret the exit status and take the appropriate action. However, it only seems to work when I a exit(0). If I try to exit with a number less than or greater than 0 the script interprets it as 255. The code follows: $program >/dev/null 2>&1 status="$?" echo $status 255 is returned on this line. Any ideas???? Brian Krupski