Skip to content

Instantly share code, notes, and snippets.

@splitline
Created December 3, 2016 07:55
Show Gist options
  • Select an option

  • Save splitline/d58541605cec47e649d141c3bd5d77e3 to your computer and use it in GitHub Desktop.

Select an option

Save splitline/d58541605cec47e649d141c3bd5d77e3 to your computer and use it in GitHub Desktop.
#include <stdio.h>
int get_from_addr(int* p){
return *p;
}
int main(){
int m = 10;
int *p = &m;
int n=get_from_addr((int *)p);
int* list[] = {p};
printf("%d", get_from_addr((int *)list[0]));
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment