Debian Codegraph @

listings/chapter-10/temp-file.c

raw
1 /***********************************************************************
2 * Code listing from "Advanced Linux Programming," by CodeSourcery LLC *
3 * Copyright (C) 2001 by New Riders Publishing *
4 * See COPYRIGHT for license information. *
5 ***********************************************************************/
6
7 struct foo
8 {
9 int x;
10 };
11
12 int main ()
13 {
14 struct foo f;
15 *((int*) &f) = 42;
16 return f.x;
17 }