<!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>FAUST compiler: compatibility.cpp File Reference</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.3 --> <div class="navigation" id="top"> <div class="tabs"> <ul> <li><a href="index.html"><span>Main Page</span></a></li> <li><a href="pages.html"><span>Related Pages</span></a></li> <li><a href="annotated.html"><span>Classes</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 List</span></a></li> <li><a href="globals.html"><span>File Members</span></a></li> </ul> </div> </div> <div class="contents"> <h1>compatibility.cpp File Reference</h1><code>#include <stdlib.h></code><br/> <code>#include <string.h></code><br/> <div class="dynheader"> Include dependency graph for compatibility.cpp:</div> <div class="dynsection"> </div> <p><a href="compatibility_8cpp_source.html">Go to the source code of this file.</a></p> <table border="0" cellpadding="0" cellspacing="0"> <tr><td colspan="2"><h2>Functions</h2></td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="compatibility_8cpp.html#a7217df0a48496637c377abb7f366d0ee">getFaustPathname</a> (char *str, unsigned int size)</td></tr> </table> <hr/><h2>Function Documentation</h2> <a class="anchor" id="a7217df0a48496637c377abb7f366d0ee"></a><!-- doxytag: member="compatibility.cpp::getFaustPathname" ref="a7217df0a48496637c377abb7f366d0ee" args="(char *str, unsigned int size)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void getFaustPathname </td> <td>(</td> <td class="paramtype">char * </td> <td class="paramname"> <em>str</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">unsigned int </td> <td class="paramname"> <em>size</em></td><td> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td><td></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="compatibility_8cpp_source.html#l00067">67</a> of file <a class="el" href="compatibility_8cpp_source.html">compatibility.cpp</a>.</p> <p>Referenced by <a class="el" href="main_8cpp_source.html#l00452">initFaustDirectories()</a>.</p> <p><div class="fragment"><pre class="fragment"><a name="l00068"></a>00068 { <a name="l00069"></a>00069 <span class="keywordtype">char</span>* path = getenv(<span class="stringliteral">"_"</span>); <a name="l00070"></a>00070 <span class="keywordflow">if</span> (path) { <a name="l00071"></a>00071 strncpy(str, path, size); <a name="l00072"></a>00072 } <span class="keywordflow">else</span> { <a name="l00073"></a>00073 <span class="comment">// prevent the case of _ undefined</span> <a name="l00074"></a>00074 strncpy(str, <span class="stringliteral">"/usr/local/bin/faust"</span>, size); <a name="l00075"></a>00075 } <a name="l00076"></a>00076 } </pre></div></p> <p><div class="dynheader"> Here is the caller graph for this function:</div> <div class="dynsection"> </div> </p> </div> </div> </div> <hr class="footer"/><address style="text-align: right;"><small>Generated on Thu Apr 29 00:00:03 2010 for FAUST compiler by <a href="http://www.doxygen.org/index.html"> <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.6.3 </small></address> </body> </html>