Escriba un suceso de diagnóstico en el registro de sucesos de diagnóstico.
#include <diag/diag_log.h>
int dlog_write(dlEntry *entry)
La subrutina dlog_write escribe un suceso de diagnóstico en el registro de sucesos de diagnóstico.
| Parámetro |
Descripción |
| entrada |
Puntero a una estructura de tipo dlEntry, que se define como sigue:
typedef struct _logEntry {
char type; /* Log Type */
char identifier[5]; /* Diagnostic log identifier */
unsigned int el_identifier; /* Error log identifier */
int timestamp;
unsigned int seqNum; /* order in which event is logged */
unsigned int el_seqNum; /* Error log sequence number */
unsigned int session; /* Diag Session's PID */
unsigned int testMode; /* Diagnostics test mode - hex value*/
resource_t *res_p; /* Resource information */
int resSize; /* Size of resource info */
void *errorInfo; /* Error information */
int errorSize; /* Size of error info */
} dlEntry;
typedef struct resource {
char name[NAME_SIZE];
int locSize;
char *location;
short set;
short msg;
char catName[NAME_SIZE];
}resource_t;
|
La subrutina dlog_write devuelve uno de los valores siguientes:
| Código de retorno |
Descripción |
| 0 |
Satisfactorio |
| -1 |
Incorrecto |
| ERROR_FS |
Indica que el sistema de archivos /var está lleno |