title: change pointer type from malloc type and free it. Does it lead to memory leak?
body: <p>I use malloc to allocate memory which is used by a pointer type. And then I forcefully modify pointer type. use free func to release the memory block. I am curious to know whether memory leak happens?<br></p>
  <p>I thought memroy was free by pointer type. &quot;int *b&quot; has wider range memory block than &quot;char *a&quot;. I compile the following code and run it. No expection happens. Could somebody tell me what happens and why?</p>
  <pre><code>#include &lt;stdlib.h&gt;
  
  int
  main(int argc, char **argv) {
          char *a = (char*)malloc(sizeof(char));
          int *b = (int*)a;
          free(b);
  }
  </code></pre>