title: Obtain filename from file pointer in C
body: <blockquote>
    <p><strong>Possible Duplicate:</strong><br>
    <a href="https://stackoverflow.com/questions/1188757/getting-filename-from-file-descriptor-in-c">Getting Filename from file descriptor in C</a><br>
    <a href="https://stackoverflow.com/questions/4305355/how-get-filename-having-file">How get fileName having FILE*?</a>  </p>
  </blockquote>
  
  
  
  <p>Is there any way where I can find the file_name from a file-pointer in C?</p>
  
  <pre><code>fp = fopen(file,"r");
  </code></pre>
  
  <p>From fp, is it possible to get the file name which I have opened?</p>