[elektro] struc

zulu zulu at gmail.hu
Wed Mar 22 09:04:11 CET 2017


> a stuckturából a relativ címeket  "offsetof" operátorral minden kiegészítés nélkül kinyerheted, de nem tudom melyik headerben találod.

struct setup
{
.
.
char xyz;
.
.

}

unsigned int xyz_addr = ( ( unsigned int ) & ( ( struct setup* ) 0 )->xyz );

http://stackoverflow.com/questions/9788679/how-to-get-the-relative-adress-of-a-field-in-a-structure-dump-c

-zulu



More information about the Elektro mailing list