Article View: comp.sys.ibm.pc.programmer
Article #717Re: listing of errorlevel codes wanted
From: Lee F Kolakowski
Date: Wed, 13 Jun 1990 06:17
Date: Wed, 13 Jun 1990 06:17
45 lines
2576 bytes
2576 bytes
On 11 Jun 90 23:44:51 GMT, silver@xrtll.uucp (Hi Ho Silver) said: > In article <Jun.11.13.23.51.1990.1616@zeppelin.rutgers.edu> sarra@zeppelin.rutgers.edu (William) writes: > $Does anyone out there have a listing of the errorlevel codes and their > $respective meanings? If so, would you please send it to me, I have a > $need for it's use in an assembly language program. > There are no assigned meanings to errorlevel codes. It's up to the > designer of each program to determine what results should be returned > using the return value you read with errorlevel, and to assign numbers to > these. Sure there are standards (loose ones anyway!), and they come from where all the good DOS programming ideas come from (Unix). Return Code Meaning 0 No Errors 1 Something went wrong (often in parameters or data) 2-infinity Something else went wrong These codes are used as valuse to exit() or return in C programs for example. For commands that test expressions like 1 == x usually return 0 if assertion is false, 1 if assertion in true, and 2 if there is a syntax error or something else. Documentation for the program should define what the exit codes are. Better error messages also relieve one from worrying about what these codes mean. -- Frank Kolakowski ====================================================================== |lfk@hx.lcs.mit.edu || Lee F. Kolakowski | |kolakowski@tropicana.mit.edu || M.I.T. | |lfk@mbio.med.upenn.edu || Dept of Chemistry | |AT&T: 1-617-253-1866 || Room 18-506 | |#include <litigate.h> || 77 Massachusetts Ave.| | || Cambridge, MA 02139 | |--------------------------------------------------------------------| | One-Liner Here! | ======================================================================
Technical Details
Message-ID:
<1990Jun13.031828.17936@athena.mit.edu>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!usc!ucsd!ucbvax!bloom-beacon!bloom-beacon!lfkReferences:
<Jun.11.13.23.51.1990.1616@zeppelin.rutgers.edu> <1990Jun11.234451.6632@xrtll.uucp>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!usc!ucsd!ucbvax!bloom-beacon!bloom-beacon!lfk From: lfk@E40-008-6.mit.edu (Lee F Kolakowski) Newsgroups: comp.sys.ibm.pc.programmer Subject: Re: listing of errorlevel codes wanted Message-ID: <1990Jun13.031828.17936@athena.mit.edu> Date: 13 Jun 90 06:17:40 GMT References: <Jun.11.13.23.51.1990.1616@zeppelin.rutgers.edu> <1990Jun11.234451.6632@xrtll.uucp> Sender: news@athena.mit.edu (News system) Organization: Mass. Inst. of Tech., Dept. of Chemistry Lines: 45 In-Reply-To: silver@xrtll.uucp's message of 11 Jun 90 23:44:51 GMT