Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ errunix(3) — AIX/RT 2.2.1

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

error

     errunix

Purpose

     Logs application errors.

Library

     Run-time Services Library (librts.a)

Syntax

     int errunix (buf, cnt)
     char *buf;
     unsigned int cnt;

Description

     The  errunix  subroutine  invokes the  application  error
     device driver to record an error log entry.  errunix is a
     C  run-time subroutine.   Device drivers  should use  the
     errsave kernel subroutine to log error messages.

     If the error device driver is not open, errunix opens it.
     Then the error log entry is written to it.

     The buf  parameter points to  a buffer that  contains the
     following information:

     1.  A word (int) that contains the class, subclass, mask,
         and type of the message, as defined in the discussion
         of "error"

     2.  An  int  that  specifies   the  number  of  words  of
         dependent  data for  the error  log entry,  including
         this int itself

     3.  Words that contain the  dependent information for the
         error log entry.  The  number of dependent data words
         must be one less than  the word count specified imme-
         diately before them.

     The other  fields of the  error log header  (length, date
     and time,  time extended, node name,  and virtual machine
     ID) are supplied for you automatically.

     The cnt  parameter specifies the  number of bytes  in the
     buffer pointed to by buf.  cnt must be a multiple of 4.

Return Value

     Upon successful completion, a value of 0 is returned.  If
     the errunix subroutine fails, an error message is written
     to  the standard  error  output,  and a  value  of -1  is
     returned.

File

     /dev/error

Related Information

     In this book:  "error."

     Device Driver Development Guide.

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026