Return Type | Function name | Arguments |
---|---|---|
const char* | ReportErrorStatus | (SMTPCode,) |
Declared and defined in file: hzMailer.cpp
Function Logic:
Function body:
const char* ReportErrorStatus (SMTPCode eSmtpCode) { static hzString smtp_code_text [] = { "0 SMTP return code indechicperable", "101 The server is unable to connect", "111 Connection refused or inability to open an SMTP stream", "200 Non standard system status message or help reply", "211 System status, or system help reply", "214 Help message (this reply is useful only to the human user)", "220 Service ready", "221 Service closing transmission channel", "235 Tells client to go ahead", "250 Requested mail action okay, completed", "251 User not local; will forward to", "252 Cannot VRFY user, but will accept message and attempt delivery", "334 Login info, either username or password", "354 Start mail input; end with <CRLF>.<CRLF>", "420 General connection timeout issue", "421 Service not available", "422 The recipient’s mailbox has exceeded its storage limit", "431 Not enough space on the disk - Expected to be temporary", "432 Recipient’s incoming mail queue has been stopped", "441 The recipient’s server is not responding", "442 The connection was dropped during the transmission.", "446 The maximum hop count was exceeded for the message", "447 Some SMTP servers will send this if they have decided to time out the client (for being too slow).", "449 Routing error", "450 Requested mail action not taken: mailbox unavailable (E.g., mailbox busy)", "451 Requested action aborted: local error in processing", "452 Action not taken: no space left", "471 Some SMTP servers return this in respose to errors on the part of the connecting client (as they see it).", "500 Syntax error, command unrecognized (This may include errors such as cmd line too long)", "501 Syntax error in parameters or arguments", "502 Command not implemented", "503 Bad sequence of commands", "504 Command parameter not implemented", "510 Bad email address", "511 Bad email address", "512 Host server for the recipient’s domain name cannot be found in DNS", "513 Address type is incorrect", "523 Size of your mail exceeds the server limits", "530 Authentication problem", "541 The recipient address rejected your message", "550 Non-existent email address", "551 User not local or address invalid.", "552 Requested mail action aborted: exceeded storage allocation", "553 Mailbox name not allowed (E.g., mailbox syntax incorrect)", "554 Transaction failed (Or in the case of a connection-opening response, No SMTP service)", "999 Not a 3 digit entity" } ; switch (eSmtpCode) { case SMTP_NOOP: return *smtp_code_text[0]; case SMTP_CONN_FAIL: return *smtp_code_text[1]; case SMTP_CONN_REFUSED: return *smtp_code_text[2]; case SMTP_STATUS_NS: return *smtp_code_text[3]; case SMTP_STATUS: return *smtp_code_text[4]; case SMTP_HELP: return *smtp_code_text[5]; case SMTP_READY: return *smtp_code_text[6]; case SMTP_QUIT: return *smtp_code_text[7]; case SMTP_GO_AHEAD: return *smtp_code_text[8]; case SMTP_OK: return *smtp_code_text[9]; case SMTP_NOTLOCAL: return *smtp_code_text[10]; case SMTP_NOVRFY: return *smtp_code_text[11]; case SMTP_LOGINFO: return *smtp_code_text[12]; case SMTP_SENDDATA: return *smtp_code_text[13]; case SMTP_TIMEOUT: return *smtp_code_text[14]; case SMTP_UNAVAILABLE: return *smtp_code_text[15]; case SMTP_MBOX_FULL: return *smtp_code_text[16]; case SMTP_DISK_FULL: return *smtp_code_text[17]; case SMTP_MBOX_HALT: return *smtp_code_text[18]; case SMTP_TIMEOUT_PX: return *smtp_code_text[19]; case SMTP_CONN_XMIT: return *smtp_code_text[20]; case SMTP_CONN_HOPS: return *smtp_code_text[21]; case SMTP_TIMEOUT_NS: return *smtp_code_text[22]; case SMTP_ROUTE: return *smtp_code_text[23]; case SMTP_MBOXBUSY: return *smtp_code_text[24]; case SMTP_PROCERROR: return *smtp_code_text[25]; case SMTP_NOSPACE: return *smtp_code_text[26]; case SMTP_CLIENT_ERR: return *smtp_code_text[27]; case SMTP_BADCOMMAND: return *smtp_code_text[28]; case SMTP_BADSYNTAX: return *smtp_code_text[29]; case SMTP_NOCOMMAND: return *smtp_code_text[30]; case SMTP_BAD_CMD_SEQ: return *smtp_code_text[31]; case SMTP_BAD_PARAM: return *smtp_code_text[32]; case SMTP_BAD_SNDR_ADDR: return *smtp_code_text[33]; case SMTP_BAD_RCPT_ADDR: return *smtp_code_text[34]; case SMTP_BAD_HOST: return *smtp_code_text[35]; case SMTP_BAD_ADDR_TYPE: return *smtp_code_text[36]; case SMTP_MSG_SIZE: return *smtp_code_text[37]; case SMTP_BAD_SERVER: return *smtp_code_text[38]; case SMTP_BAD_SENDER: return *smtp_code_text[39]; case SMTP_NACK: return *smtp_code_text[40]; case SMTP_TRYOTHER: return *smtp_code_text[41]; case SMTP_MBOXFULL: return *smtp_code_text[42]; case SMTP_BADNAME: return *smtp_code_text[43]; case SMTP_FAILED: return *smtp_code_text[44]; } return *smtp_code_text[45]; }