blank.gif (43 bytes)

Church Of The
Swimming Elephant

Index | Description | Usage | Options | Variables | Hints | Bulletproof

exit [-opts] [status]
Arguments Description
-onexit causes the next argument to be used as an exit handler.  Without an argument, the current exit handler is returned.
-noexit causes Expect to prepare to exit but stop short of actually returning control to the operating system.  The user-defined exit handler is run as well as Expect’s own internal handlers.  No further Expect commands should be executed.
status pass this exit status to the parent process.
Default = 0.

Causes Expect to exit or otherwise prepare to do so.

Upon exiting, all connections to spawned processes are closed.  Closure will be detected as an EOF by spawned processes.  exit takes no other actions beyond what the normal _exit(2) procedure does.  Thus, spawned processes that do not check for EOF may continue to run.  (A variety of conditions are important to determining, for example, what signals a spawned process will be sent, but these are system-dependent, typically documented under exit(3).) Spawned processes that continue to run will be inherited by init.

status (or 0 if not specified) is returned as the exit status of Expect.

exit is implicitly executed if the end of the script is reached.



Protect yourself from cyberstalkers, identity thieves, and those who would snoop on you.
Stop spam from invading your inbox without losing the mail you want. We give you more control over your e-mail than any other service.
Block popups, ads, and malicious scripts while you surf the net through our anonymous proxies.
Participate in Usenet, host your web files, easily send anonymous messages, and more, much more.
All private, all encrypted, all secure, all in an easy to use service, and all for only $5.95 a month!

Service Details

Have you gone to church today?
All pages ©1999, 2000, 2001, 2002, 2003 Church of the Swimming Elephant unless otherwise stated
Church of the Swimming Elephant©1999, 2000, 2001, 2002, 2003 is a wholly owned subsidiary of Packetderm, LLC.

Packetderm, LLC
210 Park Ave #308
Worcester, MA 01609