Advertisement
Archon

Offset - solution

Mar 28th, 2011
241
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.10 KB | None | 0 0
  1. struct S{
  2.   char c;
  3.   int x;
  4. };
  5.  
  6. void main(void) {
  7.   struct S s;
  8.   *(int*)((void*)&s+1) = 10;
  9. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement