Skip to content

Commit 01ac53e

Browse files
committed
fix compile error on xBSD
1 parent 4fdc2e5 commit 01ac53e

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

src/os-freebsd.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,10 @@
1919

2020
#define INADDR_ALLIGMPV3_GROUP ((in_addr_t) 0xe0000016)
2121

22+
#ifndef LOGIN_NAME_MAX
23+
#define LOGIN_NAME_MAX 256
24+
#endif
25+
2226
static inline unsigned short ip_data_len(const struct ip *ip)
2327
{
2428
#if __FreeBSD_version >= 1100030

src/os-openbsd.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,10 @@
1212
#define INADDR_ALLRTRS_GROUP INADDR_ALLROUTERS_GROUP
1313
#define INADDR_ALLIGMPV3_GROUP ((in_addr_t) 0xe0000016)
1414

15+
#ifndef LOGIN_NAME_MAX
16+
#define LOGIN_NAME_MAX 256
17+
#endif
18+
1519
static inline unsigned short ip_data_len(const struct ip *ip)
1620
{
1721
return ntohs(ip->ip_len) - (ip->ip_hl << 2);

0 commit comments

Comments
 (0)