Sophie

Sophie

distrib > Mandriva > current > x86_64 > by-pkgid > 3736f276bb1ccfbcee6cb2d27b25d981 > files > 31

openscap-devel-0.5.7-1mdv2010.1.x86_64.rpm

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<title>Open SCAP Library: /home/pvrabec/openscap/openscap-0.5.7/src/OVAL/probes/_probe-api.h Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<!-- Generated by Doxygen 1.6.1 -->
<div class="navigation" id="top">
  <div class="tabs">
    <ul>
      <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
      <li><a href="pages.html"><span>Related&nbsp;Pages</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
    </ul>
  </div>
  <div class="tabs">
    <ul>
      <li><a href="files.html"><span>File&nbsp;List</span></a></li>
      <li><a href="globals.html"><span>Globals</span></a></li>
    </ul>
  </div>
<h1>/home/pvrabec/openscap/openscap-0.5.7/src/OVAL/probes/_probe-api.h</h1><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="preprocessor">#pragma once</span>
<a name="l00002"></a>00002 <span class="preprocessor"></span><span class="preprocessor">#ifndef _PROBE_API_H</span>
<a name="l00003"></a>00003 <span class="preprocessor"></span><span class="preprocessor">#define _PROBE_API_H</span>
<a name="l00004"></a>00004 <span class="preprocessor"></span>
<a name="l00005"></a>00005 <span class="preprocessor">#include &quot;<a class="code" href="probe-api_8h.html">public/probe-api.h</a>&quot;</span>
<a name="l00006"></a>00006 <span class="preprocessor">#include &quot;probe-cache.h&quot;</span>
<a name="l00007"></a>00007 
<a name="l00012"></a><a class="code" href="structid__desc__t.html">00012</a> <span class="keyword">struct </span><a class="code" href="structid__desc__t.html" title="Holds information for item ids generation.">id_desc_t</a> {
<a name="l00013"></a>00013 <span class="preprocessor">#ifndef HAVE_ATOMIC_FUNCTIONS</span>
<a name="l00014"></a><a class="code" href="structid__desc__t.html#a40f569c0cd3250972dc47fdc6e1d41e8">00014</a> <span class="preprocessor"></span>        pthread_mutex_t <a class="code" href="structid__desc__t.html#a40f569c0cd3250972dc47fdc6e1d41e8" title="id counter lock">item_id_ctr_lock</a>;       
<a name="l00015"></a>00015 <span class="preprocessor">#endif</span>
<a name="l00016"></a><a class="code" href="structid__desc__t.html#ad9d61181be7636f97f075ce8832d987c">00016</a> <span class="preprocessor"></span>        <span class="keywordtype">int</span> <a class="code" href="structid__desc__t.html#ad9d61181be7636f97f075ce8832d987c" title="id counter">item_id_ctr</a>;        
<a name="l00017"></a>00017 };
<a name="l00018"></a>00018 
<a name="l00020"></a><a class="code" href="structglobals__t.html">00020</a> <span class="keyword">typedef</span> <span class="keyword">struct </span>{
<a name="l00021"></a>00021         <span class="comment">/* Protocol stuff */</span>
<a name="l00022"></a><a class="code" href="structglobals__t.html#a67e4584bf97abf66a97abdff392c56a6">00022</a>         <a class="code" href="structSEAP__CTX.html">SEAP_CTX_t</a> *ctx;        
<a name="l00023"></a><a class="code" href="structglobals__t.html#ac44ea20ab7469f76b7472c7c2294b877">00023</a>         <span class="keywordtype">int</span> sd;                 
<a name="l00024"></a>00024 
<a name="l00025"></a>00025         <span class="comment">/* Object cache */</span>
<a name="l00026"></a><a class="code" href="structglobals__t.html#a696fded2ef82bf829f1b1e054756e7a0">00026</a>         <a class="code" href="structpcache__t.html">pcache_t</a> *pcache;       
<a name="l00027"></a><a class="code" href="structglobals__t.html#aaea3cdc82f5f00253cc4eef779fb2c66">00027</a>         pthread_rwlock_t pcache_lock;   
<a name="l00028"></a>00028 
<a name="l00029"></a><a class="code" href="structglobals__t.html#acb6aca213c6b14ec197517cb2169e965">00029</a>         <span class="keyword">struct </span><a class="code" href="structid__desc__t.html" title="Holds information for item ids generation.">id_desc_t</a> id_desc;       
<a name="l00030"></a>00030 
<a name="l00031"></a>00031         <span class="comment">/* probe main */</span>
<a name="l00032"></a><a class="code" href="structglobals__t.html#a59f683c8c57783087a1ff92469deb227">00032</a>         <span class="keywordtype">void</span> *probe_arg;        
<a name="l00033"></a>00033 } <a class="code" href="structglobals__t.html" title="Probe&amp;#39;s global runtime information.">globals_t</a>;
<a name="l00034"></a>00034 
<a name="l00036"></a>00036 <span class="keyword">extern</span> <a class="code" href="structglobals__t.html" title="Probe&amp;#39;s global runtime information.">globals_t</a> global;
<a name="l00037"></a>00037 
<a name="l00038"></a>00038 <span class="preprocessor">#if defined(HAVE_ATOMIC_FUNCTIONS)</span>
<a name="l00039"></a>00039 <span class="preprocessor"></span><span class="preprocessor">#define GLOBALS_INITIALIZER { NULL, -1, NULL, PTHREAD_RWLOCK_INITIALIZER, {1}, NULL }</span>
<a name="l00040"></a>00040 <span class="preprocessor"></span><span class="preprocessor">#else</span>
<a name="l00041"></a>00041 <span class="preprocessor"></span><span class="preprocessor">#define GLOBALS_INITIALIZER { NULL, -1, NULL, PTHREAD_RWLOCK_INITIALIZER, {PTHREAD_MUTEX_INITIALIZER, 1}, NULL }</span>
<a name="l00042"></a>00042 <span class="preprocessor"></span><span class="preprocessor">#endif</span>
<a name="l00043"></a>00043 <span class="preprocessor"></span>
<a name="l00044"></a>00044 <span class="preprocessor">#define READER_LOCK_CACHE pthread_rwlock_rdlock (&amp;globals.pcache_lock)</span>
<a name="l00045"></a>00045 <span class="preprocessor"></span><span class="preprocessor">#define WRITER_LOCK_CACHE pthread_rwlock_wrlock (&amp;globals.pcache_lock)</span>
<a name="l00046"></a>00046 <span class="preprocessor"></span><span class="preprocessor">#define READER_UNLOCK_CACHE pthread_rwlock_unlock (&amp;globals.pcache_lock)</span>
<a name="l00047"></a>00047 <span class="preprocessor"></span><span class="preprocessor">#define WRITER_UNLOCK_CACHE pthread_rwlock_unlock (&amp;globals.pcache_lock)</span>
<a name="l00048"></a>00048 <span class="preprocessor"></span>
<a name="l00049"></a>00049 <span class="preprocessor">#define SEAP_LOCK pthread_mutex_lock (&amp;globals.seap_lock)</span>
<a name="l00050"></a>00050 <span class="preprocessor"></span><span class="preprocessor">#define SEAP_UNLOCK pthread_mutex_unlock (&amp;globals.seap_lock)</span>
<a name="l00051"></a>00051 <span class="preprocessor"></span>
<a name="l00052"></a>00052 <span class="preprocessor">#endif                          </span><span class="comment">/* _PROBE_API_H */</span>
</pre></div></div>
<hr size="1"/><address style="text-align: right;"><small>Generated on 26 Feb 2010 for Open SCAP Library by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.6.1 </small></address>
</body>
</html>