diff options
author | rsc <devnull@localhost> | 2006-04-08 23:49:08 +0000 |
---|---|---|
committer | rsc <devnull@localhost> | 2006-04-08 23:49:08 +0000 |
commit | 1f2ab849c05c3eb4eaf9088536733e351050c98e (patch) | |
tree | ac2059d90e531b9ca7cc25f43e543bad1538409c /src/cmd/rc | |
parent | 45cb54e8a6b6eb4d5308d5404960e7be40b760c1 (diff) | |
download | plan9port-1f2ab849c05c3eb4eaf9088536733e351050c98e.tar.gz plan9port-1f2ab849c05c3eb4eaf9088536733e351050c98e.tar.bz2 plan9port-1f2ab849c05c3eb4eaf9088536733e351050c98e.zip |
add exitcode
Diffstat (limited to 'src/cmd/rc')
-rw-r--r-- | src/cmd/rc/plan9ish.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/cmd/rc/plan9ish.c b/src/cmd/rc/plan9ish.c index f5e4e6a3..2e5514e1 100644 --- a/src/cmd/rc/plan9ish.c +++ b/src/cmd/rc/plan9ish.c @@ -545,3 +545,14 @@ void Memcpy(char *a, char *b, long n) void *Malloc(ulong n){ return malloc(n); } + +int +exitcode(char *msg) +{ + int n; + + n = atoi(msg); + if(n == 0) + n = 1; + return n; +} |