The CGI script should decide. If it can't cope with not finding the file,
it will not send a proper response and likely cause a 500 (or an empty
document). If it can, it should send a 404 with some HTML explaining the
problem. If you send a 500 from a properly-functioning script, it will
appear as though the script is malfunctioning when it is not.
The script is acting as part of the server, and should react as the server
would.
M. Hedlund <hedlund@best.com>