I looking a way to load function and cast it into a char ; I'd like to get bytes of it .
void myFunc();
int main()
{
char myChar =(char)&myFunc; // stuff like that
return 0;
}
void myFunc()
{
printf("hi!");
}
I hava tried to dereference my adress pointer @user2482551:
here is my new code:
#include <stdio.h>
void myFunc(){
printf("hi");
}
int main(){
unsigned int* c = (unsigned int*)(&myFunc);
printf("%d\n",*c);
return 0;
}
OUTPUT : -443987883
Do you know what does it mean ?