title: void pointer as argument
body: <p>The following C snippet:</p>
  
  <pre><code>[...] 
  void f1(void* a){
    printf("f(a) address = %p \n",a);
    a = (void*)(int*)malloc(sizeof(int));
  
    printf("a address = %p \n",a);
    *(int*)a = 3;
  
    printf("data = %d\n",*(int*)a);
  }
  
  void f(void){
    void* a1=NULL;
    printf("a1 address = %p \n",a1);
  
    f1(a1);
  
    printf("a1 address = %p \n",a1);
    printf("Data.a1 = %d\n",*(int*)a1);
  }
  [...]
  </code></pre>
  
  <p>results in</p>
  
  <pre><code>a1 address = (nil) 
  f(a) address = (nil) 
  a address = 0xb3f010 
  data = 3
  a1 address = (nil) 
  Segmentation fault (core dumped)
  </code></pre>
  
  <p>Why doesn't <code>a1</code> keep the address that has been assigned to it in the function?</p>