about summary refs log tree commit diff stats
path: root/src/common.h
blob: 6d19477cef8c2bd87e7d9535a6674c94bc5c1d33 (plain) (blame)
1
2
3
4
5
6
7
8
9
#ifndef SRC_COMMON_H_
#define SRC_COMMON_H_

#include "uv_link_t.h"

#define container_of(ptr, type, member) \
  ((type *) ((char *) (ptr) - offsetof(type, member)))

#endif  /* SRC_COMMON_H_ */