mirror of
https://sourceware.org/git/glibc.git
synced 2025-01-05 17:11:06 +00:00
Change this offsetof computation to use c89 offsetof. Tested:
This commit is contained in:
parent
bd1e10723b
commit
0ed6ae04d6
@ -40,7 +40,7 @@ struct sockaddr_un
|
||||
|
||||
#ifdef __USE_MISC
|
||||
/* Evaluate to actual length of the `sockaddr_un' structure. */
|
||||
# define SUN_LEN(ptr) ((size_t) (((struct sockaddr_un *) 0)->sun_path) \
|
||||
# define SUN_LEN(ptr) (offsetof(struct sockaddr_un, sun_path) \
|
||||
+ strlen ((ptr)->sun_path))
|
||||
#endif
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user