Skip to content

Commit cde76f8

Browse files
committed
sd-notify: fix build with recent libc
1 parent a32e0ae commit cde76f8

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

ensc-lib/sd-notify.c

+3-1
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,9 @@ union sockaddr_union {
4646
struct sockaddr_storage storage;
4747
};
4848

49-
#define offsetof(_type, _attr) (__builtin_offsetof(_type, _attr))
49+
#ifndef offsetof
50+
# define offsetof(_type, _attr) (__builtin_offsetof(_type, _attr))
51+
#endif
5052

5153
_hidden_ int sd_notify_supported(void)
5254
{

0 commit comments

Comments
 (0)