Merge pull request #848 from JimZAH/freebsd-compile-fixes

Freebsd compile fixes
This commit is contained in:
Jonathan Naylor
2025-09-20 18:44:05 +01:00
committed by GitHub
2 changed files with 3 additions and 1 deletions

View File

@@ -124,7 +124,7 @@ void CNetworkInfo::getNetworkInterface(unsigned char* info)
struct rt_msghdr *rtm;
for (char *p = buf; p < buf + size; p += rtm->rtm_msglen) {
rtm = (struct rt_msghdr *)p;
if (rtm->rtm_version != VERSION)
if (rtm->rtm_version != RTM_VERSION)
continue;
#if defined(__OpenBSD__)
struct sockaddr_in *sa = (struct sockaddr_in *)(p + rtm->rtm_hdrlen);

View File

@@ -34,6 +34,8 @@
#include <termios.h>
#if defined(__linux__)
#include <pty.h>
#elif defined(__FreeBSD__)
#include <libutil.h>
#else
#include <util.h>
#endif