Retrieving error message text
#include "btree.h"
void btcerr(int* ierr, int* ioerr, char* srname, char* msg);
The btcerr function returns the error
code (in ierr) and (if relevant) the
I/O error code (in ioerr) of the last
error encountered by the B Tree system. In addition, it will
return the name of the function which detected the error (in
srname) and an error message in
msg.
The maximum number of chars returned in
srname is BT constant
ZRNAMESZ. The maximum number of chars
returned in msg is BT constant
ZMSGSZ. Both char arrays will be
zero-padded to ZRNAMESZ and
ZMSGSZ respectively. Declaring these
arrays to be smaller than the BT constants will ensure
btcerr acts as a very effective stack
smasher.