title: How to solve open file heap error
body: <p>I am trying to put some stream from one file in a buffer then save it in a long stream and finally send it to a server but after creating a file open I have an error for heap and memory space. I am using IDE compiler which is used for Openpicus board.</p>
  
  <p>This is my code snippet:</p>
  
  <pre><code>pFile = fopen("Nini.jpg", "rb");
  if (pFile==NULL)
  {
      fputs ("File error",stderr); exit (1);
  }
  
  fclose( pFile);
  </code></pre>
  
  <p>There is a heap problem when I try to read an Image.</p>
  
  <p>Is there any solution for this? Otherwise how can I solve this problem with malloc?</p>