title: Why isn't Valgrind Working?
body: <p>I'm new to C, Ubuntu and decided to install Valgrind and test it on this simple C code:</p>
  
  <pre><code>#include &lt;stdio.h&gt;
  
  int *p;
  
  int main(void) {
      p = calloc(100, sizeof(int));
      return 0;
  }
  </code></pre>
  
  <p>I've placed this code inside sum.c file and compiled it. Then I've typed:</p>
  
  <pre><code>valgrind --tool=memcheck --leak-check=yes sum
  </code></pre>
  
  <p>in the terminal window and this is what I got:</p>
  
  <p><img src="https://i.stack.imgur.com/NBqNf.jpg" alt="enter image description here"></p>
  
  <p>I don't know if it keep looping or just get stuck, but it would stay this way until I click ctrl+d to stop it and this is what I get:</p>
  
  <p><img src="https://i.stack.imgur.com/VjcMK.jpg" alt="enter image description here"></p>
  
  <p>Am I doing something wrong ? Why can't I see that I've got a memory leak ?</p>
  
  <p>By the way, this is Ubuntu version 11.04.</p>
  
  <p>Thanks in advance</p>