Checking Exit Codes (was: Re: Trojan Horses)
John F. Haugh II
jfh at rpp386.cactus.org
Thu Nov 1 05:55:59 AEST 1990
In article <4430 at segue.segue.com> jim at segue.segue.com (Jim Balter) writes:
>You could avoid some embarrassment by testing your claims before making them
>public. It would appear that you've never actually used assert, or that when
>you do you don't follow the practice you recommend.
ah, but i do try these things out -
| Script is typescript, started Wed Oct 31 08:09:42 1990
| rpp386-> cat abort.c
| #include <signal.h>
| #include <assert.h>
| #include <stdio.h>
|
| main (argc, argv)
| int argc;
| char **argv;
| {
| signal (SIGIOT, SIG_IGN);
| assert (argc == 2);
| printf ("hi dave!\n");
| }
| rpp386-> cc -o abort abort.c
| abort.c
| rpp386-> ./abort
| Assertion failed: expr, file abort.c, line 10
| hi dave!
| rpp386-> exit
| Script done Wed Oct 31 08:10:00 1990
some people ...
--
John F. Haugh II UUCP: ...!cs.utexas.edu!rpp386!jfh
Ma Bell: (512) 832-8832 Domain: jfh at rpp386.cactus.org
"SCCS, the source motel! Programs check in and never check out!"
-- Ken Thompson
More information about the Comp.unix.internals
mailing list