summaryrefslogtreecommitdiff
path: root/sal/osl/unx
diff options
context:
space:
mode:
Diffstat (limited to 'sal/osl/unx')
-rw-r--r--sal/osl/unx/file_volume.cxx6
-rw-r--r--sal/osl/unx/system.h5
-rw-r--r--sal/osl/unx/util.c4
3 files changed, 13 insertions, 2 deletions
diff --git a/sal/osl/unx/file_volume.cxx b/sal/osl/unx/file_volume.cxx
index 543acc5f71c5..cc7f61ec6a8b 100644
--- a/sal/osl/unx/file_volume.cxx
+++ b/sal/osl/unx/file_volume.cxx
@@ -46,6 +46,12 @@
#undef HAVE_STATFS_H
#endif
+#if defined(LINUX) && defined(__FreeBSD_kernel__)
+#undef LINUX
+#define FREEBSD 1
+#endif
+
+
#if defined(SOLARIS)
#include <sys/mnttab.h>
diff --git a/sal/osl/unx/system.h b/sal/osl/unx/system.h
index 8cb77c9b7fc8..1cb0979490c0 100644
--- a/sal/osl/unx/system.h
+++ b/sal/osl/unx/system.h
@@ -123,6 +123,11 @@
# define NO_PTHREAD_PRIORITY
# define PTHREAD_SIGACTION pthread_sigaction
#endif
+
+# ifndef ETIME
+# define ETIME ETIMEDOUT
+# endif
+
#endif
#ifdef NETBSD
diff --git a/sal/osl/unx/util.c b/sal/osl/unx/util.c
index f969bfe566ec..5ba04db56021 100644
--- a/sal/osl/unx/util.c
+++ b/sal/osl/unx/util.c
@@ -162,7 +162,7 @@ static int osl_getHWAddr(const char *ifname, char* hard_addr)
* And now, the real thing: the get address
*/
-#ifdef LINUX
+#ifdef SIOCGIFHWADDR
ret=ioctl(so, SIOCGIFHWADDR, &ifr);
#else
ret=ioctl(so, SIOCGIFADDR, &ifr);
@@ -177,7 +177,7 @@ static int osl_getHWAddr(const char *ifname, char* hard_addr)
close(so);
-#ifdef LINUX
+#ifdef SIOCGIFHWADDR
memcpy(hard_addr,ifr.ifr_hwaddr.sa_data,8);
#else
memcpy(hard_addr,ifr.ifr_ifru.ifru_addr.sa_data,8);