mirror of
https://github.com/zerotier/ZeroTierOne.git
synced 2024-12-18 20:47:53 +00:00
Fix Mac tap agent abort on EINTR.
This commit is contained in:
parent
72a724f075
commit
c56831767e
@ -79,7 +79,7 @@ ext/x64-salsa2012-asm/salsa2012.o:
|
|||||||
$(CC) $(CFLAGS) -c ext/x64-salsa2012-asm/salsa2012.s -o ext/x64-salsa2012-asm/salsa2012.o
|
$(CC) $(CFLAGS) -c ext/x64-salsa2012-asm/salsa2012.s -o ext/x64-salsa2012-asm/salsa2012.o
|
||||||
|
|
||||||
mac-agent: FORCE
|
mac-agent: FORCE
|
||||||
$(CC) -O -s -o MacEthernetTapAgent osdep/MacEthernetTapAgent.c
|
$(CC) -Ofast -o MacEthernetTapAgent osdep/MacEthernetTapAgent.c
|
||||||
$(CODESIGN) -f -s $(CODESIGN_APP_CERT) MacEthernetTapAgent
|
$(CODESIGN) -f -s $(CODESIGN_APP_CERT) MacEthernetTapAgent
|
||||||
|
|
||||||
one: $(CORE_OBJS) $(ONE_OBJS) one.o mac-agent
|
one: $(CORE_OBJS) $(ONE_OBJS) one.o mac-agent
|
||||||
@ -138,11 +138,4 @@ distclean: clean
|
|||||||
|
|
||||||
realclean: clean
|
realclean: clean
|
||||||
|
|
||||||
# For those building from source -- installs signed binary tap driver in system ZT home
|
|
||||||
#install-mac-tap: FORCE
|
|
||||||
# mkdir -p /Library/Application\ Support/ZeroTier/One
|
|
||||||
# rm -rf /Library/Application\ Support/ZeroTier/One/tap.kext
|
|
||||||
# cp -R ext/bin/tap-mac/tap.kext /Library/Application\ Support/ZeroTier/One
|
|
||||||
# chown -R root:wheel /Library/Application\ Support/ZeroTier/One/tap.kext
|
|
||||||
|
|
||||||
FORCE:
|
FORCE:
|
||||||
|
@ -336,6 +336,10 @@ int main(int argc,char **argv)
|
|||||||
FD_SET(STDIN_FILENO,&rfds);
|
FD_SET(STDIN_FILENO,&rfds);
|
||||||
FD_SET(s_bpffd,&rfds);
|
FD_SET(s_bpffd,&rfds);
|
||||||
if (select(s_bpffd+1,&rfds,&wfds,&efds,(struct timeval *)0) < 0) {
|
if (select(s_bpffd+1,&rfds,&wfds,&efds,(struct timeval *)0) < 0) {
|
||||||
|
if ((errno == EAGAIN)||(errno == EINTR)) {
|
||||||
|
usleep(10);
|
||||||
|
continue;
|
||||||
|
}
|
||||||
return ZT_MACETHERNETTAPAGENT_EXIT_CODE_READ_ERROR;
|
return ZT_MACETHERNETTAPAGENT_EXIT_CODE_READ_ERROR;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user