aboutsummaryrefslogtreecommitdiff
path: root/common.c
diff options
context:
space:
mode:
authorPřemysl Janouch <p.janouch@gmail.com>2015-11-21 15:15:49 +0100
committerPřemysl Janouch <p.janouch@gmail.com>2015-11-21 19:00:56 +0100
commitd4cbc576e28ab48474438db7820d47ce24c2099c (patch)
treeeeac1424b609f9e865a83a35fd79a8b7972a017f /common.c
parent9bb9c9868c0523b81acf078f330c85c4b8086bdd (diff)
downloadxK-d4cbc576e28ab48474438db7820d47ce24c2099c.tar.gz
xK-d4cbc576e28ab48474438db7820d47ce24c2099c.tar.xz
xK-d4cbc576e28ab48474438db7820d47ce24c2099c.zip
degesch: typos, cleanups
Diffstat (limited to 'common.c')
-rw-r--r--common.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/common.c b/common.c
index f76554d..43e53b9 100644
--- a/common.c
+++ b/common.c
@@ -41,6 +41,9 @@
return 0; \
BLOCK_END
+#define CONTAINER_OF(pointer, type, member) \
+ (type *) ((char *) pointer - offsetof (type, member))
+
// --- To be moved to liberty --------------------------------------------------
static void