この行が何をするのか理解できません:
((struct Example*) 0x10000)
私はテストプログラムを書きました:
#include <stdio.h>
struct Elf{
int bla;
char bla2;
};
int main(){
struct Elf *elfPtr;
printf("Before casting: %p\n", elfPtr);
elfPtr = ((struct Elf *)0x10000);
printf("After casting: %p\n", elfPtr);
return 0;
}
出力は次のとおりです。
キャスト前: 0xb776dff4
キャスト後:0x10000
この行はこれだけですか?
elfPtr = 0x10000