Read a message delivery failure log from a message file.
argument informationstatus = PMDF_read_failure_log
(dq_context, date, date_len, line, line_len)
| Argument | Data type | Access | Mechanism |
|---|---|---|---|
| dq_context | context pointer | read/write | reference |
| date | descriptor | read/write | reference |
| date_len | unsigned word | write | reference |
| line | descriptor | read/write | reference |
| line_len | unsigned word | write | reference |
argument informationstatus = PMDFreadFailureLog
(dq_context, date, date_len, line, line_len)
int PMDFreadFailureLog (dq_context, date, date_len,
line, line_len)
PMDF_dq **dq_context;
char *date;
int *date_len;
char *line;
int *line_len;
dq_context
A message dequeue context created with PMDF_dequeue_initialize.date
A buffer to receive the time stamp indicating when the log record was written. Length must be at least ALFA_SIZE bytes. (ALFA_SIZE for PMDFreadFailureLog.)date_len
Length in bytes of the time stamp. Callers using PMDFreadFailureLog must, on input, supply the maximum length in bytes of date.line
A buffer to receive the log line read from the message delivery failure log. Length must be at least BIGALFA_SIZE-1 bytes. (BIGALFA_SIZE for PMDFreadFailureLog.)line_len
Length in bytes of the line read. Callers using PMDFreadFailureLog must, on input, supply the maximum length in bytes of line.
Messages may contain a delivery failure log detailing why previous delivery attempts, if any, failed. This log may be read only after the message content (headers and body) has been read. If no log is present, then PMDF__EOF will be returned on the first read attempt. If however a log is present, then it may be read with repeated calls to PMDF_read_failure_log. After reading the last line of the log from the message, a subsequent call to PMDF_read_failure_log will return the PMDF__EOF status code. That is, if two log lines remain to be read, then the next two calls will read those two lines and return PMDF__OK. A third call will not read any line and will return PMDF__EOF. The delivery failure log is generated with PMDF_dequeue_message_end when it defers a message. It is also generated with PMDF_defer_message.Return Values
| PMDF__OK | Normal, successful completion. |
| PMDF__BADCONTEXT | Illegal or corrupt context. No data returned; no line read. |
| PMDF__EOF | End of message. |
| PMDF__FATERRLIB | Call to LIB$SCOPY_R_DX failed owing to a fatal internal error in the OpenVMS Run Time Library. No data returned although a line was read. |
| PMDF__INSVIRMEM | Insufficient virtual memory: call to LIB$GET_VM made by LIB$SCOPY_R_DX has failed. No data returned although a line was read. |
| PMDF__INVSTRDES | Invalid string descriptor for either date or line: descriptor for one or both has an invalid value in its DSC$B_CLASS field. No data returned; however, a line was read. |
| PMDF_NO | Message read point is at the wrong location; must first read to the end of the message body with PMDF_read_line or PMDF_read_text. |
| PMDF__STRTRU | Supplied string was too long; value truncated to fit. |