Skip to content
This repository has been archived by the owner on Apr 22, 2023. It is now read-only.

process: use exit 1 for uncaughtException #6191

Merged
merged 2 commits into from Sep 7, 2013

Commits on Sep 7, 2013

  1. process: Fix regression from a5dba82

    Respect numeric string args to process.exit(code)
    isaacs committed Sep 7, 2013
    Copy the full SHA
    39aafcf View commit details
    Browse the repository at this point in the history
  2. process: use exit 1 for uncaughtException

    Since it is Unix tradition to use exit code 1 for general-purpose script
    bail-out, and the way of doing that in Node is to throw an exception and
    not catch it, it makes the most sense to exit with 1 when an exception
    goes uncaught.
    
    Move the `Invalid Argument` exit to 9, so that it's something specific,
    and clear that it's a node internal error.
    
    Also, document the exit codes that we use.
    isaacs committed Sep 7, 2013
    Copy the full SHA
    b30a03e View commit details
    Browse the repository at this point in the history