mirror of
https://github.com/servalproject/serval-dna.git
synced 2024-12-23 23:12:31 +00:00
Fix android build, related to issue #76 fix
This commit is contained in:
parent
1f49ee47ae
commit
025726dcab
@ -28,6 +28,7 @@ SERVALD_LOCAL_CFLAGS = \
|
||||
-DHAVE_JNI_H=1 -DHAVE_STRUCT_UCRED=1 -DHAVE_CRYPTO_SIGN_NACL_GE25519_H=1 \
|
||||
-DBYTE_ORDER=_BYTE_ORDER -DHAVE_LINUX_STRUCT_UCRED -DUSE_ABSTRACT_NAMESPACE \
|
||||
-DHAVE_BCOPY -DHAVE_BZERO -DHAVE_NETINET_IN_H -DHAVE_LSEEK64 -DSIZEOF_OFF_T=4 \
|
||||
-DHAVE_LINUX_IF_H \
|
||||
-I$(NACL_INC) \
|
||||
-I$(SQLITE3_INC)
|
||||
|
||||
|
13
monitor.c
13
monitor.c
@ -155,22 +155,11 @@ void monitor_poll(struct sched_ent *alarm)
|
||||
/* Check for new connections */
|
||||
/* We don't care about the peer's address */
|
||||
ignored_length = 0;
|
||||
while (
|
||||
#ifdef HAVE_LINUX_IF_H
|
||||
(s = accept4(alarm->poll.fd, NULL, &ignored_length,O_NONBLOCK))
|
||||
#else
|
||||
(s = accept(alarm->poll.fd,NULL, &ignored_length))
|
||||
#endif
|
||||
!= -1
|
||||
) {
|
||||
while ((s = accept(alarm->poll.fd,NULL, &ignored_length))!= -1) {
|
||||
monitor_new_client(s);
|
||||
}
|
||||
if (errno != EAGAIN) {
|
||||
#ifdef HAVE_LINUX_IF_H
|
||||
WHY_perror("accept4(O_NONBLOCK)");
|
||||
#else
|
||||
WHY_perror("accept");
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user