Sophie

Sophie

distrib > Mandriva > 2007.0 > x86_64 > media > main-release > by-pkgid > a4c98df40e78f6c892308fd6841f950a > files > 906

lib64db4.2-devel-4.2.52-11mdv2007.0.x86_64.rpm

<!--$Id: runtime.so,v 10.20 2003/10/18 19:15:59 bostic Exp $-->
<!--Copyright 1997-2003 by Sleepycat Software, Inc.-->
<!--All rights reserved.-->
<!--See the file LICENSE for redistribution information.-->
<html>
<head>
<title>Berkeley DB Reference Guide: Run-time error information</title>
<meta name="description" content="Berkeley DB: An embedded database programmatic toolkit.">
<meta name="keywords" content="embedded,database,programmatic,toolkit,b+tree,btree,hash,hashing,transaction,transactions,locking,logging,access method,access methods,Java,C,C++">
</head>
<body bgcolor=white>
<table width="100%"><tr valign=top>
<td><h3><dl><dt>Berkeley DB Reference Guide:<dd>Debugging Applications</dl></h3></td>
<td align=right><a href="../debug/compile.html"><img src="../../images/prev.gif" alt="Prev"></a><a href="../toc.html"><img src="../../images/ref.gif" alt="Ref"></a><a href="../debug/printlog.html"><img src="../../images/next.gif" alt="Next"></a>
</td></tr></table>
<p>
<h3 align=center>Run-time error information</h3>
<p>Normally, when an error occurs in the Berkeley DB library, an integer value
(either a Berkeley DB specific value or a system <b>errno</b> value) is
returned by Berkeley DB.  In some cases, however, this value may be
insufficient to completely describe the cause of the error, especially
during initial application debugging.</p>
<p>There are four methods intended to provide applications with additional
run-time error information:
<a href="../../api_c/env_set_errcall.html">DB_ENV-&gt;set_errcall</a>, <a href="../../api_c/env_set_errfile.html">DB_ENV-&gt;set_errfile</a>,
<a href="../../api_c/env_set_errpfx.html">DB_ENV-&gt;set_errpfx</a>, and <a href="../../api_c/env_set_verbose.html">DB_ENV-&gt;set_verbose</a>.</p>
<p>If the environment is configured with these methods, many Berkeley DB errors
will result in additional information being written to a file or passed
as an argument to an application function.</p>
<p>The Berkeley DB error-reporting facilities do not slow performance or
significantly increase application size, and may be run during normal
operation as well as during debugging.  Where possible, we recommend
that these options always be configured and the output saved in the
filesystem.  We have found that this often saves time when debugging
installation or other system-integration problems.</p>
<p>In addition, there are three methods to assist applications in
displaying their own error messages: <a href="../../api_c/env_strerror.html">db_strerror</a>,
<a href="../../api_c/env_err.html">DB_ENV-&gt;err</a>, and <a href="../../api_c/env_err.html">DB_ENV-&gt;errx</a>.  The first is a superset of
the ANSI C strerror function, and returns a descriptive string for any
error return from the Berkeley DB library.  The <a href="../../api_c/env_err.html">DB_ENV-&gt;err</a> and
<a href="../../api_c/env_err.html">DB_ENV-&gt;errx</a> methods use the error message configuration options
described previously to format and display error messages to appropriate
output devices.</p>
<table width="100%"><tr><td><br></td><td align=right><a href="../debug/compile.html"><img src="../../images/prev.gif" alt="Prev"></a><a href="../toc.html"><img src="../../images/ref.gif" alt="Ref"></a><a href="../debug/printlog.html"><img src="../../images/next.gif" alt="Next"></a>
</td></tr></table>
<p><font size=1><a href="../../sleepycat/legal.html">Copyright (c) 1996-2003</a> <a href="http://www.sleepycat.com">Sleepycat Software, Inc.</a> - All rights reserved.</font>
</body>
</html>