mirror of
https://gitlab.nic.cz/labs/bird.git
synced 2024-11-08 12:18:42 +00:00
18 lines
356 B
C
18 lines
356 B
C
|
/*
|
||
|
* BIRD Library
|
||
|
*
|
||
|
* (c) 1998 Martin Mares <mj@ucw.cz>
|
||
|
*
|
||
|
* Can be freely distributed and used under the terms of the GNU GPL.
|
||
|
*/
|
||
|
|
||
|
#ifndef _BIRD_BIRDLIB_H_
|
||
|
#define _BIRD_BIRDLIB_H_
|
||
|
|
||
|
/* Ugly structure offset handling macros */
|
||
|
|
||
|
#define OFFSETOF(s, i) ((unsigned int)&((s *)0)->i)
|
||
|
#define SKIP_BACK(s, i, p) ((s *)((char *)p - OFFSETOF(s, i)))
|
||
|
|
||
|
#endif
|