title: Setting variable to NULL after free
body: <p>In my company there is a coding rule that says, after freeing any memory, reset the variable to <code>NULL</code>. For example ...</p>
  
  <pre><code>void some_func () 
  {
      int *nPtr;
  
      nPtr = malloc (100);
  
      free (nPtr);
      nPtr = NULL;
  
      return;
  }
  </code></pre>
  
  <p>I feel that, in cases like the code shown above, setting to <code>NULL</code> does not have any meaning. Or am I missing something?</p>
  
  <p>If there is no meaning in such cases, I am going to take it up with the "quality team" to remove this coding rule. Please advice.</p>