net/boinc-client: don't crash getting MAC address.
Reported by: thurners@nicsys.de
This commit is contained in:
parent
9f1f612973
commit
78ae8baa8f
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=459631
3 changed files with 14 additions and 2 deletions
|
@ -4,7 +4,7 @@
|
|||
PORTNAME= boinc-client
|
||||
PORTVERSION= 7.8.6
|
||||
DISTVERSIONPREFIX= client_release/7.8/
|
||||
PORTREVISION= 5
|
||||
PORTREVISION= 6
|
||||
CATEGORIES= net
|
||||
|
||||
MAINTAINER= ler@FreeBSD.org
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
--- client/hostinfo_unix.cpp.orig 2018-01-14 16:39:30 UTC
|
||||
--- client/hostinfo_unix.cpp.orig 2018-01-14 10:07:52 UTC
|
||||
+++ client/hostinfo_unix.cpp
|
||||
@@ -164,7 +164,9 @@ extern "C" {
|
||||
// The following is intended to be true both on Linux
|
||||
|
|
12
net/boinc-client/files/patch-client_mac__address.cpp
Normal file
12
net/boinc-client/files/patch-client_mac__address.cpp
Normal file
|
@ -0,0 +1,12 @@
|
|||
--- client/mac_address.cpp.orig 2018-01-21 22:41:16 UTC
|
||||
+++ client/mac_address.cpp
|
||||
@@ -262,6 +262,9 @@ int get_mac_address(char* address) {
|
||||
return -1;
|
||||
}
|
||||
hw_addr = (struct ether_addr *)&(item->lifr_lifru.lifru_enaddr);
|
||||
+#else
|
||||
+ /* Need to teach this how on FreeBSD, but for now don't crash */
|
||||
+ return -1;
|
||||
#endif
|
||||
strcpy(address, ether_ntoa(hw_addr));
|
||||
#ifdef HAVE_STRUCT_LIFCONF
|
Loading…
Reference in a new issue