Thanks again that worked out, just to show you how bogus the int made the address when you stored it (printing worked for some reason)...
Code:
#include <stdio.h>
int main()
{
char a = 'y';
unsigned long add,user_add;
printf("Enter an address:\n");
scanf("%llu", &user_add);
add = (unsigned long)&a;
printf("a = c:%c\n\n", a);
printf("&a = d:%d lu:%lu llu:%llu\n", &a);
printf("&user_add = d:%d lu:%lu llu:%llu\n",user_add );
}
OUTPUT:
Enter an address:
12345
a = c:y
&a = d:-776806577 lu:140191114246560 llu:140191114241920
&user_add = d:12345 lu:140191114246560 llu:140191114241920
So i don't know what the difference is between using llu and lu, but they both seem to work.